4 Replies Latest reply on Jun 16, 2011 3:23 AM by harihisu

    How to load lots of images synchronously

    yancaoshi Level 1

      HI all,

       

      I want to cache lots of images locally with URLLoader and need to know those fails. I can add listener to event IOErrorEvent.IO_ERROR.

      A variable can be used to save the file name I want to load last time. Then in the error handler I can know which file is not loaded correctly.

      However, since images are loaded asynchronously, which is how URLLoader works, the firstly loaded image may not the firstly completed. That means the variable may contain incorrect file name.

       

      Is there a better way to approach? I just want to log the error loadings.

       

      Regards,

      Felix