Need Parameters for a "Stop All Sound" button

  • Thread starter pureevilentertainment
  • Start date
P

pureevilentertainment

Hi All,

I've created a webpage with various buttons that each play a different
sound file located on my local drive. I need a button that will stop
any sound that is currently playing.

Here is an example of the code:
<applet code="fphover.class" codebase="./" width="104" height="24">
<param name="color" value="#000080">
<param name="hovercolor" value="#0000FF">
<param name="textcolor" value="#FFFFFF">
<param name="bgcolor" value="#000000">
<param name="effect" value="fill">
<param name="text" value="Ref Whistle">
<param name="sound" valuetype="ref" value="1Sound%20FX%20-%20Ref
%20whistle.au">
</applet></p>

Now keep in mind there are a couple dozen of these batches in the html
page. I cannot figure out how to make one simple button that I can
click to make any active sound file to stop.

Thanks!

Paul
 
A

Andrew Thompson

..
I've created a webpage with various buttons that each play a different
sound file located on my local drive. I need a button that will stop
any sound that is currently playing.

Here is an example of the code:
<applet code="fphover.class" .. ....
..there are a couple dozen of these batches in the html
page. I cannot figure out how to make one simple button that I can
click to make any active sound file to stop.

When the stop button is pressed, call
AppletContext.getApplets() and enumerate
the elements looking for instances of the
fphover applet class. When you find one,
call the FPHover.stopAllClips() method
(which you will need to code).
 
P

pureevilentertainment

When the stop button is pressed, call
AppletContext.getApplets() and enumerate
the elements looking for instances of the
fphover applet class. When you find one,
call the FPHover.stopAllClips() method
(which you will need to code).

I have no idea what any of that means. Sorry. I'm new at this. To
elaborate more... I've made a sound board for an internet radio show,
so that I can play sound effects by clicking on buttons I've made
within Frontpage. My problem is that sometimes I want the clips to
stop playing before their file is done.

Is there any simple code that I can use, with a button, that will
immediately stop any sound playing within the page?

Thanks and again, sorry for being such a green-thumb.

Paul
 
A

Andrew Thompson

On Sep 6, 5:24 pm, (e-mail address removed) wrote:
....
Is there any simple code that I can use, with a button, that will
immediately stop any sound playing within the page?

No. I suggest you hire a Java programmer.
 
R

Roedy Green

When the stop button is pressed, call
AppletContext.getApplets() and enumerate
the elements looking for instances of the
fphover applet class. When you find one,
call the FPHover.stopAllClips() method
(which you will need to code).

Of course that won't necessarily stop sound generated the various
other ways. See http://mindprod.com/jgloss/sound.html

You might be able to do a platform-dependent way by finding something
low level to abort all access to the sound card. That would require
some JNI.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,756
Messages
2,569,535
Members
45,007
Latest member
OrderFitnessKetoCapsules

Latest Threads

Top