Actionscript Q
- Started
- Last post
- 9 Responses
- drbyers
Does anyone know how to check load progress on an image loaded with IMG tags inside of text fields within Flash MX Pro?
Any response or tutorial link would be greatly appreciated.
- version30
no and why would you want to? that would only make it take longer to view the file and cause a muck for any text involved in the text box, not to mention added file size to your swf
- drbyers0
i need it because I'm doing event-based programming.
i.e. when this image finally loads, it will trigger something else in the movie.
and I can't preload the image, becuase I want to keep my scripting flexible.
- ********0
sounds like you're trying to do something because you like the name "event based programming" without really understanding what's the point of doing it.
- function820
you want to check the progress of a externally loaded image?
- Mimio0
What's wrong with using the builtin loader class? it tells you all the properties of the file while its loading.
- unfittoprint0
u could parse the text using a text replace defined function, retrieve the src for each img tag, load separately the images to a holder mc with its visibility set to false.
onLoadComplete for all images, you can finally paste the text. Since the images were loaded before, they're already cached, they'll appear [almost] immediatelly.
You can now safely remove the holder mc.
- ********0
maybe an ass-backwards way of doing this, but...
have the mc loop while onData for it is true, after it exits the loop (when the HTML is finished), gotoAndPlay or trigger your event. Its a similar approach to a preloader or loading status.
- Donzo0
What unfit said seems like the best way, but if the user doesn't have caching on there might be a problem.
Why not parse the html (as unfit said) and recreate the content as text files and holder_mcs without putting them back in the html?
- Xboxlover0
Thanks for the input!