Solved

problems playing sound object in a loaded swf

Posted on 2006-07-17
4
173 Views
Last Modified: 2010-04-03
Senerio

I have a swf file that loads another swf file using the loader component. The swf file loaded is called "postBlog" and the instance name givien to the loader control is "loaderblog"

In the loaded swf "postBlog" i have the following sound object defined on the first frame of the movie

firstSound=new Sound();
firstSound.attachSound("intro01");

then on frame 30 i tell the time line to play this sound object using the following action script

_root.firstSound.start()


This works fine when the movie clip is run alone however the sounds does not play when the clip is loaded into another clip

I have tried changing the action script to as follows but have had no luck

_level1.firstSound.start(0,0);

and

this.firstSound.start(0,0);

But these do now work. I am obviously targeting this sound object incorrectly but am at aloss on the correct syntax to target sounds objects defined in loaded movie clips using the loader component

any insite would be greatly appreciated
0
Comment
Question by:mediatimebomb
  • 3
4 Comments
 
LVL 23

Accepted Solution

by:
Zeffer earned 250 total points
ID: 17125646
these should work..

_root.loaderblog.firstSound.start();

or

this._lockroot = true;
firstSound= new Sound();
firstSound.....etc

Z
0
 

Author Comment

by:mediatimebomb
ID: 17126020
what's going on in the second method?

i would like to find a solution that would allow the sound to play from the original swf or from the loaded swf
0
 

Author Comment

by:mediatimebomb
ID: 17126118
ok i tried the first method with no success.  What is happening in the second suggestion i am confused on what

this._lockroot = true is doing

0
 

Author Comment

by:mediatimebomb
ID: 17126161
ok figured it out thank you for your help
0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
how can i learn adobe flex step by step 4 116
bandwidth 5 74
Why is this simple, masked Flash animation flickering? 20 199
Actionscript in Flash 3 70
Sometimes you know that one object has a specific child in it, but you can't find the child. This happened to me when I was trying to code some actionScript to make a toolbar work with its embedded buttons.  My partner had created the toolbar usi…
I have been doing hardcore actionscripting for some time; and needless to say I have faced a lot of problems in just understanding others' code rather than understanding what the code executes. A programmer's life can become hell when there are a lo…
The goal of the tutorial is to teach the user how to how to record live broadcast.
The goal of the tutorial is to teach the user how to use the auto adjust feature and what the different options do. When your video is not working right you can choose the auto adjust feature to help choose your settings.

839 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question