views:

111

answers:

1

I've looked for the solution to my problem on SO, Google and Bing, but to no avail.

NB This is regarding AS3/CS5 on Windows 7 Pro x64.

I have a SWF that loads another SWF in AS3.

Yesterday morning it was working fine.

Then I made a bunch of changes to another SWF, completely separate, and to some XML content files and the next time I ran the project the second SWF started to flash and scroll through its content once it was loaded by the first SWF.

I couldn't figure out what I did to cause the problem and have NO clue!

I wasted an entire work day for what should have taken only 10 minutes.

The loading SWF does load the problem SWF and trace statements in the document class for the loading SWF execute fine but it does NOT appear that the second SWF's document class constructor is executed as I don't see any trace statements in it being executed.

I had the same issue issue on Thursday and it turned out to be a syntax error in a class relevant to the second SWF and that was quickly solved.

However, NO code relevant to the problem SWF was changed this time around and the problem SWF compiles fine with strict mode on.

I copied the code from my laptop (Windows 7 Pro 32bit) where I verified everything works fine and I got the same problem once on my dev PC.

I don't remember changing anything to my PC Flash/Actionscript development environment and want to tear out hair I don't have!!!

For now I'm working on my laptop but that's not a permanent solution.

Does anyone know HOW I can systematically track down this problem???

I'm beginning to regret I ever got into Flash/AS3; it's just not possible to run a diff on the entire dev environment and find out exactly what's wrong.

I don't see anything in the Windows event logs. Are there Flash logs that I could take a look at? So far I haven't found anything and curse the day I looked upon Flash.

Any ideas??

Thank you! Chris

+1  A: 

Since you state that the second SWF doesn't take account of the Document Class, you should be able to reproduce the error by creating a basic test swf with a Document Class.

Sometimes, going back to basics can be a good approach to problem solving...

If you're not able to reproduce the error with a basic SWF , this would indicate an error in your second SWF. If it's such a big system, it would make sense to break it down in smaller components , this would help identify the problem and probably make for a better structure.

If you can reproduce the error , then I would suggest to look at reinstalling...

PatrickS
Thanks @PatrickS. The first SWF compiles fine, though I should try to compile the second SWF with a basic class, you're right. I hope I don't need to re-install as this problem might re-occur. I deleted my Flasm comment as it appears to be useless in my case. I suppose I could figure out what the problem is if I could disassemble the file. Ah, wish I stayed away from the Flash world.
Heckflosse_230
So it does not (apparently) ignore a pretty much empty document class when compiling. I then added back all the code into the document class but left it with the new temporary class name and it did catch a syntax error I put in and the flashing/scrolling issue appeared again. However, before it ignored syntax error issue. I'm a bit ahead. I don't want to re-install because I'll be back at square one if this problem ocurrs again.
Heckflosse_230
Your environment seems to have passed the basic test, so I wouldn't worry about reinstalling for now. It doesn't look like a random issue. Although it doesn't yet make sense why your app would work on one platform and not another, the fact you're able to reproduce the error in a new swf would suggest that the error is in the code, not your environment. Would it be possible to break your code in smaller components?
PatrickS
Yes, that's the next step, break it down a bit. Though I'll have to do it later and work on the laptop for now. Will post a solution once I find one, in case someone finds it useful one day. Thanks for your help!
Heckflosse_230
You're welcome! Please let us know when it's solved...
PatrickS