# Volume Slider!

**URL:** <https://forum.kirupa.com/t/volume-slider/27860>\
**Category:** Uncategorized\
**Created:** [August 7, 2003, 9:38am UTC](https://forum.kirupa.com/t/volume-slider/27860 "2003-08-07T09:38:10Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![balroo](https://avatars.discourse-cdn.com/v4/letter/b/b5e925/32.png) [@balroo](https://forum.kirupa.com/u/balroo)\
**Post date:** [August 7, 2003, 9:38am UTC](https://forum.kirupa.com/t/volume-slider/27860/1 "2003-08-07T09:38:10Z")

</div>

hi there,

ive just tried a tutorial of Kirupa for a volume slide feature, take a look:

[http://www.kirupa.com/developer/mx/volume\_slider.htm](http://www.kirupa.com/developer/mx/volume_slider.htm)

basically ive done it succesfully except for knowing afterwards that it was being aimed at one partucular sound loop…

is there any adjustment or anything i need to do in order to make this volume slider adjust the volume for all sounds within the swf file??

could someone help me out,…i would really appreciate it!! :thumb:

thnx in advance!! 🙂

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [August 8, 2003, 4:55pm UTC](https://forum.kirupa.com/t/volume-slider/27860/2 "2003-08-08T16:55:03Z")

</div>

Well, I don’t think you can use something like SetGlobalVolume or anything, so try this:

[AS]  
onClipEvent (load) {  
mySound = new Sound();  
mySound.loadSound(“sound2.mp3”, false);  
}  
onClipEvent (enterFrame) {  
downloaded = mySound.getBytesLoaded();  
total = mySound.getBytesTotal();  
if (downloaded != total) {  
\_root.dl = “downloading song…”;  
} else {  
complete = 1;  
\_root.dl = “”;  
}  
mySound.setVolume(\_root.volume);  
sound2.setVolume(\_root.volume);  
sound3.setVolume(\_root.volume);  
sound4.setVolume(\_root.volume);  
sound5.setVolume(\_root.volume);  
//Add all sound objects here to control their volume.  
}  
[/AS]

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [August 8, 2003, 5:10pm UTC](https://forum.kirupa.com/t/volume-slider/27860/3 "2003-08-08T17:10:30Z")

</div>

You actually can use a global to set all the sound volumes i believe. If you just create a new global sound object and dont attach it to anything, controlling the volume on that object should control all the others.
