• Post Reply Bookmark Topic Watch Topic
  • New Topic

Mute the Volume of PC  RSS feed

 
Maryam Nouhnejad
Ranch Hand
Posts: 39
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Dear friends,
I have encountered a problem... I don't know how to mute the volume of my PC using Java??.......
I searched in JDK 1.5 ... MIDIChannel interface looked useful ... I wrote some peices of code and used setMute of this interface ... but nothing happened...
I suppose I'm wrong... may be I should do it in another way........help me please... how can I mute the volume of my PC??

thanks in advance,
Maryam
 
Maryam Nouhnejad
Ranch Hand
Posts: 39
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Please sb help me...
 
William Brogden
Author and all-around good cowpoke
Rancher
Posts: 13078
6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Controlling the volume of sound output is up to the operating system and/or the drivers for your hardware. This is something that varies tremendously between operating systems and sound generating hardware. The standard Java library is pretty primitive about sound - you can only affect the sound your Java program is generating.

If you can find an operating system command to mute the sound on your particular system, Java might be able to execute it.

Advanced sound capabilities for Java are in the java media framework you might try looking there.

Bill
[ November 17, 2006: Message edited by: William Brogden ]
 
Jeevan Philip
Ranch Hand
Posts: 41
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Execute the tool below for windows

http://magic.aladdin.cs.cmu.edu/wp-uploads/cmdmute.zip
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!