Topic: Continuation of last post (volume controls) (Page 1 of 1) Pages that link to <a href="https://ozoneasylum.com/backlink?for=25048" title="Pages that link to Topic: Continuation of last post (volume controls) (Page 1 of 1)" rel="nofollow" >Topic: Continuation of last post (volume controls) <span class="small">(Page 1 of 1)</span>\

 
aponex
Obsessive-Compulsive (I) Inmate

From:
Insane since: Feb 2005

posted posted 02-18-2005 20:11

Hey I?m back again? In addition to my last post I also need to know what?s the best way to increase and decrease the volume on my windows media player using custom controls. Basically all I have is a button for increasing and button for decreasing volume. I wrote a java code based on what I know but I gave up on it. I don?t even think it?s even close to what I need. The code is as follows:

function setVolume(intVolume)
{
intVolume=((intVolume-8)*1250);
Player.Volume=intVolume;
}



I've also tried this code that I found on a tutoral, it didn't work for me but maybe there's something I'm not doing right. It is as follows:

function IncreaseVolume ()
{
Player.settings.volume = Player.settings.volume + volumeIncrement;
document.all.volumeBar.style.width = VolumeBarLength * (Player.settings.volume/100);
if (volumeText) {document.all.volume.innerHTML = Player.settings.volume + '%';}
}




The object Id for the embedded player is ?Player?. What I need is a function that will be able to increase and decrease the volume by certain increments, enough to make a significant different but not too excessive. The Microsoft website was no help so I?ve turned to the Asylum. Like I said I'm far from a java guru so any help is appreciated.

-APONE-

(Edited by aponex on 02-18-2005 20:19)

GRUMBLE
Paranoid (IV) Mad Scientist

From: Omicron Persei 8
Insane since: Oct 2000

posted posted 02-19-2005 11:55

here is some info on controling the media player using javascript:

(kewl long MS url)
http://msdn.microsoft.com/library/en-us/dnwmt/html/windows_media_player_advanced_scripting_for_cross_browser_functionality__jchc.asp

--
www.embege.com

aponex
Obsessive-Compulsive (I) Inmate

From:
Insane since: Feb 2005

posted posted 02-22-2005 20:41

Thanks GRUMBLE,
but this doesn't help me at all. I kinda gave up on these MS sites long ago. I'm still searching for a solution and my code seems to be similar to a lot of others i've seen so I know i'm getting close but I can't get it to work properly.

-APONE-



Post Reply
 
Your User Name:
Your Password:
Login Options:
 
Your Text:
Loading...
Options:


« BackwardsOnwards »

Show Forum Drop Down Menu