You'll have to use FlashVars. Here's some background information straight from Adobe's site:
http://kb.adobe.com/selfservice/viewContent.do?externalId=tn_16417Essentially, FlashVars are name/value pairs you set in the Embed tag of a swf. The name/values you set are then available on the root timeline of the swf. Now, here's the kicker, your example requires an additional step. When you click on the back button in the photogallery you're going to have to append a name/value pair to the url. (i.e.
http://www.google.com?skip=true). Then, you'll have to use a javascript function that pulls the name/value pair in the url and changes the FlashVar you have set on your first page from one value to another (i.e. skip=true vs. skip=false).
Here's a recap:
1. add FlashVar to first swf Embed
2. add javascript function to first swf html page that will look for name/value pairs in the url, and change the FlashVar
3. on the back button press, append name/value pair to the url (you'll want to read up on navigateToURL() in its entirety here: [url]http://livedocs.adobe.com/flash/9.0/ActionScriptLangRefV3/[/url hint: flash.net.navigateToURL])
4. On frame 1 on your first page animation, throw code there to tell the movie to go to the last frame if skip == true
This is the simplist example I can think of. I'm sure there are other ways, maybe someone else can weigh in?