We received a slightly puzzling bug report for our charting components today. The user changed the export frame for classes in his movie to 2 in order to allow for a preloader on frame 1. As soon as he did this, the components stopped working.
He was very diligent in his report and provided examples and steps to reproduce the problem. I followed his steps and immediately saw the same problem he was reporting–the components no longer worked. Without immediately realizing what was wrong, I went as far as creating SWFs in with classes exported on frame 1, the default, and on frame 2 and compared the SWFs with ASV and saw that the differences were really minor.
But there was one important difference that was a problem–the components were being exported before the classes were available. Both the user and I had forgotten to uncheck Export in First Frame for the components. So of course they didn’t work. Uncheck that option and put them on the stage after the classes frame, and everything works fine.
As it turns out, the Flash MX 2004 Help on this issue is very clear. It provides steps for setting the export frame for classes and then explains the ramifications for doing that and that you have to uncheck Export in First Frame for components. Guess I need to rtfm more often….
Keith at http://www.bit-101.com/blog has an exhaustive discussion of the implications of non first frame exporting in fmx2004. Also, somewhere on there is some jsfl to automagically uncheck export in first frame.
Hi,
thanks for posting this, I had exatly the same problem; it’s been bothering me for a while and I now see a solution ^^
Any ideas on how to get the Alert Component to work when the export frame is changed and I’ve unchecked the Export in First Frame on the Alert
I managed to get a simple solution to my problem above. I just placed an instance of the Alert Component off the stage with an instance name of comp_Alert in the same frame as my classes we set to export. When I tested this though, it showed a blank alert box in the centre of the screen. So on that frame I added
destroyObject(“comp_Alert”);
and it all worked a treat. Hope this helps someone else