Invert Number of a volume slider

Hi,
I made a volumeslider, but the problem is that the sound plays at 100% when the slider is down and at 0% when the slider is up.
Of course every volumeslider does the opposite.
Can anyone help me to adjust this code so down, the volume becomes 0% and up 100%?
sliderVolume.onPress = function() {
    this.startDrag(false,150,150,150,250);
sliderVolume.onRelease = sliderVolume.onReleaseOutside = function() {
    this.stopDrag ();
    var volumePercentage: Number=100 - ((barVolume._y+barVolume._height) - this._y);
    mySong.setVolume(1*volumePercentage);
    txtVolumePercentage.text = volumePercentage+ "%";
Thanks,
Geert

Hey Ned,
thanks for the quick reply. It was very helpfull. After doing what you said it got louder when going up. When I changed the Number to 0 instead of 100 it worked completely. So thanks for the help.
Geert

Similar Messages

  • Can volume slider be locked in place?

    I do an Internet radio show and play songs directly from iTunes.  We strive to have all DJs play their music at the same volume.  The volume slider in the iTunes window does not have a number scale on it, and moves when I accidentally move the cursor in that area.   Without a number scale to revert to, is there any way to lock the slider in place to retain my optimum volume setting?
    Thanks.

    like i say you need to change the MTU on the router to 1400.
    Got the setup page 192.168.0.1 and then on the left you will see "Advanced" under that you will see "wan setup" click on it, now you should see "MTU size(in bytes) the number there should be 1500 change this to 1400 and then click apply now you should be ok.
    Tony in Paddington, London on UKonline22(11Mb down 756up).
    Hore this helps.

  • Can the volume slider show value in non-DB?

    I remember seeing the volume slider in the channel strip showing normal number values instead of db, but I cannot find a way to changes this. Anyone knows?
    André

    The worst part is that once you get used to using the db scale, and then open an old song that is set to numbers (MIDI 0-127) there is no way to set it to db. Why ever remove a function?

  • How to create volume slider for flash cs 5 using action script 2.0?

    how to create volume slider for flash cs 5 using action script 2.0?the output should like if user want to hear sound in slow pitch,medium pitch or high pitch(slow to high pitch anything).i have attach this sound to button with using this code:
    stop();
    mySoundBtn.onRelease = function () {
              mySoundC = new Sound(this);
              mySoundC.attachSound("mySoundClip");
              mySoundC.start(0, 10);  //10 represents the number of loops
              gotoAndPlay(2);
    This sound plays till 3-4 scene ahead.
    Can anyone help me?

    Hey thnx Ned.
    this sites are really helpful.but,i have used sound through button.so how it is possible to attavh the link with slider.i have created slider also.
    Below is my slider code for sound.
    onClipEvent (load) {
        mySound1 = new Sound();
        mySound1.loadSound((myScale)+"/"+(myTanpura)+"/"+(myTanpuraSwar)+"/"+(myTanpuraTempo)+".w av", true);
        mySound1.onSoundComplete = function() {
        mySound1.start();
        mySound1.start(0.058,999);
    onClipEvent (enterFrame) {
        downloaded = mySound1.getBytesLoaded();
        total = mySound1.getBytesTotal();
        if (downloaded != total) {
            _root.dl = "You have to buy this software...";
        } else {
            complete = 1;
            _root.dl = "";
        mySound1.setVolume(ratio * 2);
    This code is working for slider.I mean it scrolls the slider.but it dosent make any effect to sound.
    Below is my button code.
    stop();
    mySoundBtn4.onRelease = function () {
              mySoundC = new Sound(this);
              mySoundC.attachSound("mySoundClip4");
              mySoundC.start(0, 300);  //10 represents the number of loops
              gotoAndPlay("play1");
    this is on button's frame.not exactly on button.
    Button and Slider both are on diffrent scene.
    Can you plese help me out?

  • HP Dv7t Volume Slider Button Problem...​.........?

    Hello, i own a Hp Dv7t Notebook, in the past week my laptop has been acting differnet, My promblem starts with the volume slider button. The volume slider button is located at the top of my notebook and is touch sensitie when you run your finger over it. Before my problem the button when used would adjust the volume and make a "clicking" sound while displaying a window showin g the current volume level......Now, for some reason the button doesnt work in the same fashion as before......now when u use it the button makes no clicking sounds nor displays a windows that it used to, this problem is rather small but it has also enabled my volume to be lower than normal.......but i must say that the button does still work, it adjusts the volume as it should but doesnt do the other things..........i am computer literate and do no how to fix many of my system malfunctions, but this one has me stumped........Sorry for such a long post but i would really appriciate some help, THANK YOU!!!!!!!!
    HP Customer;
    Evan C. Ford
    Email Me Please    <text removed for privacy>
    Message Edited by WendyM on 10-26-2009 12:05 PM

    It sounds like my problem was very similar to tlee's.
    All it took was doing a cold reboot, I found the solution here: http://h30434.www3.hp.com/t5/Hardware/HP-dv4-1225d​x-Quick-Launch-Button-Problems/m-p/272053#M29072
    When tech support couldnt fix it I asked for the number to call and return my laptop. Finding that thread changed my mind.

  • My speaker doesn't work when I try to listen to music or open up a quick time file, however they seem to work perfectly when I listen to a voice memo (p.s. the volume slider disappears in a song page and even in the multi tasking bar)

    my speaker doesn't work when I try to listen to music or open up a quick time file, however they seem to work perfectly when I listen to a voice memo (p.s. the volume slider disappears in a song page and even in the multi tasking bar)

    Thanks for your solution, it wasn't quite what solved the problem but i remembered that i had a bit of salt water on my phone recently and spraying the charging port with an anti-oxide spray solved my problem, do you mind if i ask, how is the charging port related with the volume or/and speakers?

  • Hi there. I have a problem with sound on my 4s. When you move the volume slider up, it sounds well. But when I move the volume slider down I will hear barely and unclear sound in my headphone.I tried different headphones but result is same as old one.Help

    Hi there. I have a problem with sound on my 4s. When you move the volume slider up, it sounds well. But when I move the volume slider down I will hear barely and unclear sound in my headphone.I tried different headphones but result is same as old one.Help

    Try A and B
    (A) Restart iPad
    1. Hold down the Sleep/Wake button until the red slider appears.
    2. Drag the slider to turn off iPad.
    3. Turn iPad back on, hold down the Sleep/Wake until the Apple logo appears
    (B) Reset iPad
    Hold down the Sleep/Wake button and the Home button at the same time for at least ten seconds, until the Apple logo appears
    Note: Data will not be affected.

  • How to fix my volume slider so i can see it on the screen

    I have a dv6-1355dx and i had to restore it to the factory settings and ever since then when i try my volume slider it works still i just dont see it on the screen anymore any one that knows what this could be would help me out alot

    Welcome to the HP Forum!
    bpc4587 wrote:
    I have a dv6-1355dx and i had to restore it to the factory settings and ever since then when i try my volume slider it works still i just dont see it on the screen anymore any one that knows what this could be would help me out alot
    What is the installed operating system and version (32-bit or 64-bit)?
    Do you mean the volume slider from the taskbar or the one from the audio software/
    The audio driver can be found on the driver and software download section of the web support portal for your notebook.  This is the page you seek. Use the dropdown to select the correct version of the installed operating system for your notebook. Right-click Computer and select properties to see which version is installed in your notebook.
    Kind regards,
    erico
    ****Please click on Accept As Solution if a suggestion solves your problem. It helps others facing the same problem to find a solution easily****
    2015 Microsoft MVP - Windows Experience Consumer

  • I have an I phone 4 and since I upgrade to the lastest ios  6.1.3 , my volume slider is missing. The sound works when but I can't mute or turn up or turn down the volume. I've tried a hard reset , reboot, blowing air in the dock and earrplug jack. :-(

    I tried almost evrything to restore my volume slider( + & - ). My phone rings, plays music and every other sound but I can't mute or put  the volume up r down with the side buttons.. My volume slider bar is missing. This is only simce I upgraded to iso 6.1.3 .. What's with that?? I figured out how to manually  mute the phone through (General, Accessibitily) by muting the bell for sound and unmuting the bell for silent mode. But what a freaken pain, when you have to take all those extra steps to turn your volume up or down or  mute your Iphone??
    We have no Apple Store here so no luck to bring it in to get looked at.. Please , does anyone out there know what else I coold do???
    Cheers

    Does it work with headphones plugged in?  That is typically the culprit, the device mistakenly believes that a pair of headphones are plugged in.

  • How can I re-enable the volume slider?

    Sometimes I want to play around with the volume curve, and sometimes that doesn't work out or isn't needed anymore. But when I delete all volume curve points (i.e. click left of the curve, press backspace) the volume slider doesn't come back. It seems like a bug, anybody know a workaround?

    its not a bug. click on the little upside down triangle just to the left of the volume knob. after you click on the triangle the track volume will appear with a rectangular blue box click on that to turn off the volume curves.
    By the way if you on the words track volume the track pan will also appear.

  • IPod Touch 1st Gen and 3.1 update DELETES volume slider

    I had a perfectly working iPod Touch 1st Gen/16GB until I updated to 3.1 software. Now I do not have a volume slider.
    Yes headphones are in but there is no place to adjust the volume. There is previous, next arrows and play and pause AND its centered in the rectangular area, but no volume slider.
    I have restored it 3x in various ways. I have tried 5 times to downgrade the operating system but ALWAYS get an error, so it never completes. Of course the ipsw files where found using google because there isn't any links that work on Apple's site for previous iPhone software. If I try to restore to 3.1 right after that it goes through perfectly.
    So it seems that Apple has locked out downgrading once you upgrade! All I want is my volume slider back. How can I get it back if 3.1 deletes it everytime and I can't go back to the previous operating system?
    Thank you.

    I too have had this exact same problem, except that I was running 3.0 and hadn't updated to 3.1. I put my ipod on the table overnight, after listening to it, and when I picked it up the next morning, theres no volume slider. I never even unplugged the headphones. Double clicking the home button while on the home screen would bring up the popup to skip songs, and there it says "Dock Connection" even though it not connected to a computer. Multiple reboots an no effect. I've tried different sets of headphones, to no effect. Its like the iPod isnt detecting them being plugged in. The worst part is i DO get sound in the headphones, but no volume control, and the sound level is turned really low. So the headphones ARE working.
    I updated to 3.1 just now, and the problem has NOT been fixed. Theres no way anywhere in the settings to adjust the volume. Theres only a limit slider, so I have no way to turn up the volume loud enough to actually HEAR things.

  • I can't get the volume to work when I watch a you tube video, there's no volume slide under the play button, and my volume control on my I pad won't do anything either, but the volume of all my alarms and sounds works perfect, what can I do??

    I can't get the volume to work when I watch a you tube video, there's no volume slide under the play button and my volume control on my I pad don't do anything to help, but yet my volume works perfect on everything else, what can I do???

    do u have your ipad doing airplay because that could happen

  • Cannot use volume slider in Windows 7 via bootcamp

    Hello everyone. My MBP spec is 15" i7. I've installed a Windows 7 via Bootcamp. after that, i installed the drivers using my Apple Os X disk. But after all that, I can't use the volume slider to control the volume. why is that?

    Boot Camp Support Software 5.0.5033

  • Volume Slider on HP DV9000 (DV9700) Does not work,using Windows 7

    Not too long ago, the volume button,next to the volume slider on my laptop stopped working.  After checking postings that I found,  was able to resolve the volume on/off issue, by shutting down the PC,unplug and take the battery out and put it back in.  I still cannot get the volume slider to work!  I can go into the sound mixer and control the volume,but it would be nice to make it work again.  I had this problem with the original OS (Vista) and have upgraded to 7 Ultimate and it still continues.
    This question was solved.
    View Solution.

    @evangelos
    Hi,
    Download and install:
    HP Quick Launch Buttons here (ver 6.50.13.1 for 32/64 bit Win7)
    If you want to have on-screen visuals and associated sounds that are displayed and heard when adjusting volume then download and install:
    3VRX here (ver 2.5 for 32/64 bit Win7)
    Note:
    Here is YouTube video which shows what can be done with this software.
    You need more solutions? Check below link:
    Windows 7 Upgrade Guide for dv6000/dv9000 models
    ** Say thanks by clicking the "Thumb up" icon which is on the left. **
    ** Make it easier for other people to find solutions, by marking my answer with "Accept as Solution" if it solves your issue. **

  • Where is the volume slider in iTunes 12.0.1?

    where is the volume slider in iTunes 12.0.1?

    try dragging the corners to make the itunes window bigger .... the volume slider will show up

Maybe you are looking for

  • BI Admin Cockpit - Portal Runtime Error

    Hi, We have BI 7.0 (NW 7.0 with EHP1) BI_CONT 704. It is a dual stack (ABAP+JAVA) installation. We have deployed "BI Administration 1.0" on the java stack. All the configurations are done as per notes. Error is faced when trying to access BI Admin co

  • Loading Xlet via .jar

    Hi everybody, i've got an Xlet containing about 100 classes and some resources. Since the startup-time is beyond the pale when files are loaded separetely by the object carousel, I want to load them with some .jar-files. Therefore I wrote a custom Cl

  • Creating a score set - please help- I'm going crazy

    OK- deep breath ...........I'm trying to create a score set for 4 instruments. I read the manual, then tried everything on p 765........... I started first with the tracks in the Arrange area.- with and without rubber bands - and because this didn't

  • Photo gallery code

    I have found some code that I'd like to use to create a photo gallery. When I paste it into the code area of Dreamweaver 8 and preview it, it just appears as the text rather than the gallery. Can anyone tell me how I can fix this? Many thanks Nic

  • Mp4 videos in my library wont update to iPod

    I have a few mp4 videos which I can watch in the itunes viewer, that when I do the automatic update they wont go to the ipod. Anyone know why?