You can watch a sound loading with an interval tracing the Sound.getBytesLoaded method.

----- Original Message ----- From: "Marc Hoffman" <[EMAIL PROTECTED]>
To: "Flashcoders mailing list" <flashcoders@chattyfig.figleaf.com>
Sent: Saturday, May 13, 2006 11:46 PM
Subject: Re: [Flashcoders] Stop loading


How do you know the sound is no longer loading?

At 07:32 PM 5/13/2006, you wrote:
Yes thats exactly what i found, loading another sound is the only way to stop a sound from loading once its started.

----- Original Message ----- From: "Gerry Creighton" <[EMAIL PROTECTED]>
To: "Flashcoders mailing list" <flashcoders@chattyfig.figleaf.com>
Sent: Saturday, May 13, 2006 6:21 PM
Subject: Re: [Flashcoders] Stop loading


What about using the following code... s.loadSound("",true);
<code>
var s:Sound = new Sound();
s.loadSound("Finish Line.mp3" , true);
s.start(999,1);
function stopSong(){
//s.stop();
s.loadSound("",true);
clearInterval(myTimer);
trace("stopSong called");
}
myTimer= setInterval(stopSong , 5000);
</code>

This would load nothing.
Gerry



On May 13, 2006, at 6:01 PM, Patrick Matte wrote:

Your code will actually stop the streaming sound from playing, but not from
being downloaded from the server.



Le 13/05/06 17:14, « Gerry Creighton » <[EMAIL PROTECTED]> a écrit :

I just tested this code and it worked as it should.
<code>
var s:Sound = new Sound();
s.loadSound("Finish Line.mp3" , true);
s.start(999,1);
function stopSong(){
s.stop();
clearInterval(myTimer);
trace("stopSong called");
}
myTimer= setInterval(stopSong , 10000);
</code>

I of course put the swf and the mp3 in the same directory to test  this.
I used the setInterval just to do a quick test that it shuts off
after 10 seconds.

Gerry
..................................................................... ...
...
http://www.thespikeranch.com
Certified Macromedia Flash MX Designer
..................................................................... ...
...

On May 13, 2006, at 3:23 PM, Patrick Matte wrote:

Whats the best way to stop a sound from loading ? I fired the
Sound.loadsound() method but suddenly for a reason, I need to  stop the
loading right away.

Same thing with MovieClipoader. Will the MovieClipLoader.unloadClip
method
simply stop the downloading of the image ?


_______________________________________________
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com

_______________________________________________
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


_______________________________________________
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com

_______________________________________________
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com
_______________________________________________
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


_______________________________________________
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com
_______________________________________________
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com

Reply via email to