Computers & Internet Logo

Related Topics:

Posted on Aug 24, 2011
Answered by a Fixya Expert

Trustworthy Expert Solutions

At Fixya.com, our trusted experts are meticulously vetted and possess extensive experience in their respective fields. Backed by a community of knowledgeable professionals, our platform ensures that the solutions provided are thoroughly researched and validated.

View Our Top Experts

I want to stop java - Sun Computers & Internet

1 Answer

Anonymous

Level 3:

An expert who has achieved level 3 by getting 1000 points

All-Star:

An expert that got 10 achievements.

MVP:

An expert that got 5 achievements.

Vice President:

An expert whose answer got voted for 100 times.

  • Master 794 Answers
  • Posted on Aug 24, 2011
Anonymous
Master
Level 3:

An expert who has achieved level 3 by getting 1000 points

All-Star:

An expert that got 10 achievements.

MVP:

An expert that got 5 achievements.

Vice President:

An expert whose answer got voted for 100 times.

Joined: Jan 23, 2011
Answers
794
Questions
0
Helped
289295
Points
1864

Hi nhl_kiwi_fan,

Just to clarify, on what device would like to stop the Java application? May I have the brand and model?

Thank you for using FixYa.

Add Your Answer

×

Uploading: 0%

my-video-file.mp4

Complete. Click "Add" to insert your video. Add

×

Loading...
Loading...

Related Questions:

0helpful
1answer

Why does java stop working trying to download a movie on mp3 rocket on windows 10?

Possibly Rocket not compatible with newest version of Java. You might have to download an older version of Java. I could check out the Rocket requirements page to see what version of Java they recommend.

If you need further help, I’m available over the phone at https://www.6ya.com/expert/josh_8e641fe76e154b02

4helpful
1answer

Java application stop

Java Application has stopped that means your software has been corrupt.
So please visit the nearest care according to your handset and get your mobile FLASHED and install the latest software.
Install you java application software and make sure it has been installed.
thanks for using fixya
Aug 19, 2011 • Cell Phones
0helpful
1answer

Java Platform SE binary has stopped working

Hi.
I suggest you download a new java plaform installer, cause sometimes not all java installers that you download are working some of them are broken because of the convertion.and remember not to run any other software when installing java sometimes it cause the instalation to crash.

plz. rate my comment tnx.
0helpful
1answer

Am having problem installing Java. I have tried severla times to download it but along the finishing, it keeps wrting a notice saying that Java is already installed in my computer. But testing my computer...

Hi,

Are you getting the below exception
Error 1714. The older version of Java cannot be removed

If yes , the you can try Offline installation of Java.The below URL gives the complete details -
http://java.com/en/download/help/error_1714.xml
0helpful
1answer

I am trying to install an Java 6 update 20

If you are using any form of Anti Virus software, it could be stopping the installation process. Go to the SUN Java website, and download the latest version. Save it to your desktop. Take a moment to reboot your machine completely. DO NOT start any other programs after rebooting. Stop or disable your ANTI VIRUS software. Install the JAVA update and reboot. The update should work, and upon rebooting after the install, your AV software should start again. If it is still disabled, enable it.
1helpful
4answers

Java stops working

Have you downloaded the latest version 6 update 16 of Java Runtime from

http://www.java.com/en/download/manual.jsp
0helpful
1answer

Trouble Installing Java

make sure the %ProgramFiles%\Java\jre6\ and %APPDATA%\Sun\Java\jre1.6.0_10\ directories are empty. and than try to reinstall it.
0helpful
1answer

How to play audio clip in java

  • Create an AudioClip object
  • Load .au sound file into AudioClip
  • Play sounds once or loop continuously
  • Stop playback


Here's how the code for these steps looks:
import java.applet.*;
AudioClip ac = getAudioClip(getCodeBase(), soundFile);
ac.play(); //play once
ac.stop(); //stop playing
ac.loop(); //play continuously


It would seem logical to use this same code to play audio clips in a Java application. Unfortunately, if you do that you will get errors from the compiler. Why? Because the AudioClip object and the getAudioClip() method are part of the java.applet package -- and are not part of applications. The good news is we can dive down and make things work ourselves.
The trick to solving this problem is to use some undocumented features that are provided by Sun in its JDK. Taking a peek inside the classes.zip file from the Sun JDK (using any of the various zipfile utilities), we find not only the standard Java packages such as java.applet but also sun.audio. (These are in the directory sun/audio.)
The sun.audio package contains everything we need to be able to play audio clips! Here's the code:
import sun.audio.*; //import the sun.audio package
import java.io.*;
//** add this into your application code as appropriate
// Open an input stream to the audio file.
InputStream in = new FileInputStream(Filename);
// Create an AudioStream object from the input stream.
AudioStream as = new AudioStream(in);
// Use the static class member "player" from class AudioPlayer to play
// clip.
AudioPlayer.player.start(as);
// Similarly, to stop the audio.
AudioPlayer.player.stop(as);


To use a URL as the audio stream source, substitute the following for the input stream and audio stream setup:
AudioStream as = new AudioStream (url.openStream());


Playing the audio stream continuously adds a bit more complexity:
// Create audio stream as discussed previously.
// Create AudioData source.
AudioData data = as.getData();
// Create ContinuousAudioDataStream.
ContinuousAudioDataStream cas = new ContinuousAudioDataStream (data);
// Play audio.
AudioPlayer.player.play (cas);
// Similarly, to stop the audio.
AudioPlayer.player.stop (cas);
Not finding what you are looking for?

36 views

Ask a Question

Usually answered in minutes!

Top Sun Computers & Internet Experts

Rob Hill
Rob Hill

Level 3 Expert

1483 Answers

Narseman

Level 3 Expert

1092 Answers

Brad Brown

Level 3 Expert

19190 Answers

Are you a Sun Computer and Internet Expert? Answer questions, earn points and help others

Answer questions

Manuals & User Guides

Loading...