This content has been marked as final. Show 9 replies
right click on your sound in your library, click linkage, tick export for actionscript and assign a linkage id (say soundID). you can then use:
I've done that but it's not really clear to me how I test the name of the file (i.e. /index.asp) and where I should put the code to do that.
As I say, I really am very new to this.
attach the first two lines to frame 1 of your swf.
attach the 3rd line whereever you want your sound to start. that may be right after the first 2 lines if you want the sound to start when your swf starts.
attach the 4th line (without comment indicator //) where you want your sound to stop. that may be attached to a button that directs the user to a new page.
Thanks for that. The thing is that this swf is used on everypage as the left navigation. I do want the sound to play when the page loads but I only want it to play for the home page of the site (i.e index.asp) and I don't know how to test or query what page I'm on using action script.
are you using a html frameset?
No, I have the flash file in an ASP include that appears on every page
No that didn't seem to work.
It is possible to get a popup to appear when the final swf runs in the page to tell me what the value of this._url is.
I tried Alert.show(this._url) but that didn't work.
Any other suggestions gratefully recieved.
for debugging purposes place a dynamic textfield (with instance name tf) on-stage in you navigation swf.
in frame 1 of you navigation swf attach