Cast error in java sound

Hey, i got a little run-time error:
Exception in thread "AWT-EventQueue-0" java.lang.ClassCastException: com.sun.media.sound.PortMixer$PortMixerPort
the code segment it occurs at is here:
case 0:
      targetDataLine1 = (TargetDataLine)mixer1.getLine(targetInfo);
      targetDataLine2 = targetDataLine1;
}Some background info: I used getTargetLines() method of Mixer to obtain an arraylist of all the Line.Info objects (for targetLines) in a mixer, then I passed this into a GUI class, and made a vector to display in combo box. once user selects an item, it casts it back into Line.Info, and calls the mixer's "getLine()" method to retrieve the line. But I get the cast error. I know you can cast from Line to TargetDataLine (since TargetDataLine is a subinterface of Line) -- and I saw it on a tutorial, so I don't know what's wrong. Any help?
If you need more info, just tell me.

But still, the tutorial I looked at
(http://java.sun.com/j2se/1.5.0/docs/guide/sound/progr
ammer_guide/chapter3.html#113154)
still showed it down-casting from a Line object to a
TargetDataLine object.
You need to understand the difference between a reference and an object. The object itself was a TargetDataLine object, otherwise the cast wouldn't have worked. The reference to it was of type Line.
// obj is a reference of type Object. The object it points to is a String:
Object obj = "I am a String";
// Which explains why this works:
String s = (String)obj;
// and why this fails:
Integer i = (Integer)obj;
Not to mention, the java API says that the
getLine(Line.Info) object returns an object of type
Line.
And I still don't understand why you can't cast from
a superclass to a subclass. I know intuitively, it
makes since, since not all RECTANGLES are SQAURES,
but all SQUARES are RECTANGLES. But still, I know
enough programming to remember numerous instances of
casting Object as other classes....
See above.
Oh, and what does the $ symbol in
com.sun.media.sound.PortMixer$PortMixerPort mean?It means that the the class PortMixerPort is an inner class (or nested class, I never remember the difference :-) in the class PortMixer.

Similar Messages

  • Error 500: java.lang.NoClassDefFoundError

    I'm trying to setup a web app and I opened up it's index.faces page on internet explorer, but it's giving me this huge error message on the page instead:
    Error 500: java.lang.NoClassDefFoundError: Error while defining class: <Class 1> This error indicates that the class: <Class 2> could not be located while defining the class: <Class 1> This is often caused by having the class at a higher point in the classloader hierarchy Dumping the current context classloader hierarchy: ==> indicates defining classloader *** indicates classloader where the missing class could have been found ***[0] com.ibm.ws.classloader.CompoundClassLoader@6a6cfd0b Local ClassPath: /mp/app/WebSphere6/AppServer/profiles/TestProfile01/installedApps/TestCell/ClarityPasswordResetEAR.ear/ClarityPasswordReset_WEB.war/WEB-INF/classes:/mp/app/WebSphere6/AppServer/profiles/TestProfile01/installedApps/TestCell/ClarityPasswordResetEAR.ear/ClarityPasswordReset_WEB.war/WEB-INF/lib/commons-collections.jar:/mp/app/WebSphere6/AppServer/profiles/TestProfile01/installedApps/TestCell/ClarityPasswordResetEAR.ear/ClarityPasswordReset_WEB.war/WEB-INF/lib/icu4j_3_4_1.jar:/mp/app/WebSphere6/AppServer/profiles/TestProfile01/installedApps/TestCell/ClarityPasswordResetEAR.ear/ClarityPasswordReset_WEB.war/WEB-INF/lib/wsac_taglib_210.jar:/mp/app/WebSphere6/AppServer/profiles/TestProfile01/installedApps/TestCell/ClarityPasswordResetEAR.ear/ClarityPasswordReset_WEB.war/WEB-INF/lib/commons-beanutils.jar:/mp/app/WebSphere6/AppServer/profiles/TestProfile01/installedApps/TestCell/ClarityPasswordResetEAR.ear/ClarityPasswordReset_WEB.war/WEB-INF/lib/commons-logging.jar:/mp/app/WebSphere6/AppServer/profiles/TestProfile01/installedApps/TestCell/ClarityPasswordResetEAR.ear/ClarityPasswordReset_WEB.war/WEB-INF/lib/commons-digester.jar:/mp/app/WebSphere6/AppServer/profiles/TestProfile01/installedApps/TestCell/ClarityPasswordResetEAR.ear/ClarityPasswordReset_WEB.war/WEB-INF/lib/wsf_core.jar:/mp/app/WebSphere6/AppServer/profiles/TestProfile01/installedApps/TestCell/ClarityPasswordResetEAR.ear/ClarityPasswordReset_WEB.war/WEB-INF/lib/wsf_persistence.jar:/mp/app/WebSphere6/AppServer/profiles/TestProfile01/installedApps/TestCell/ClarityPasswordResetEAR.ear/ClarityPasswordReset_WEB.war/WEB-INF/lib/struts.jar:/mp/app/WebSphere6/AppServer/profiles/TestProfile01/installedApps/TestCell/ClarityPasswordResetEAR.ear/ClarityPasswordReset_WEB.war/WEB-INF/lib/jsf-ibm.jar:/mp/app/WebSphere6/AppServer/profiles/TestProfile01/installedApps/TestCell/ClarityPasswordResetEAR.ear/ClarityPasswordReset_WEB.war/WEB-INF/lib/wsf_util.jar:/mp/app/WebSphere6/AppServer/profiles/TestProfile01/installedApps/TestCell/ClarityPasswordResetEAR.ear/ClarityPasswordReset_WEB.war Delegation Mode: PARENT_FIRST ==>[1] com.ibm.ws.classloader.JarClassLoader@1784790283 Local Classpath: /mp/app/WebSphere6/AppServer/profiles/TestProfile01/installedApps/TestCell/ClarityPasswordResetEAR.ear/ClarityPasswordReset_BO.jar:/mp/app/WebSphere6/Custom-Libs/WSF_supplement/wscommon.jar Delegation mode: PARENT_FIRST [2] com.ibm.ws.classloader.ProtectionClassLoader@6e37bd08 [3] com.ibm.ws.bootstrap.ExtClassLoader@7d213d09 [4] sun.misc.Launcher$AppClassLoader@7dc43d09 [5] sun.misc.Launcher$ExtClassLoader@7dc03d09 ---Original exception--- java.lang.NoClassDefFoundError: <Class 2> at java.lang.ClassLoader.defineClass0(Native Method) at java.lang.ClassLoader.defineClass(ClassLoader.java(Compiled Code)) at java.security.SecureClassLoader.defineClass(SecureClassLoader.java(Compiled Code)) at com.ibm.ws.classloader.CompoundClassLoader._defineClass(CompoundClassLoader.java(Compiled Code)) at com.ibm.ws.classloader.CompoundClassLoader.findClass(CompoundClassLoader.java(Compiled Code)) at com.ibm.ws.classloader.CompoundClassLoader.loadClass(CompoundClassLoader.java(Compiled Code)) at java.lang.ClassLoader.loadClass(ClassLoader.java(Compiled Code)) at com.ibm.ws.classloader.ReloadableClassLoader.loadClass(ReloadableClassLoader.java(Compiled Code)) at com.ibm.ws.classloader.CompoundClassLoader.loadClass(CompoundClassLoader.java(Compiled Code)) at java.lang.ClassLoader.loadClass(ClassLoader.java(Compiled Code)) at java.beans.Beans.instantiate(Beans.java:202) at java.beans.Beans.instantiate(Beans.java:63) at com.sun.faces.config.ManagedBeanFactory.newInstance(ManagedBeanFactory.java:204) at com.sun.faces.application.ApplicationImpl.createAndMaybeStoreManagedBeans(ApplicationImpl.java:913) at com.sun.faces.el.VariableResolverImpl.resolveVariable(VariableResolverImpl.java:84) at com.ibm.faces.databind.SelectItemsVarResolver.resolveVariable(SelectItemsVarResolver.java:38) at com.sun.faces.el.impl.NamedValue.evaluate(NamedValue.java:125) at com.sun.faces.el.impl.ComplexValue.evaluate(ComplexValue.java:146) at com.sun.faces.el.impl.ExpressionEvaluatorImpl.evaluate(ExpressionEvaluatorImpl.java:243) at com.sun.faces.el.ValueBindingImpl.getValue(ValueBindingImpl.java:156) at com.sun.faces.el.ValueBindingImpl.getValue(ValueBindingImpl.java:137) at javax.faces.component.UIOutput.getValue(UIOutput.java:147) at com.sun.faces.renderkit.html_basic.HtmlBasicInputRenderer.getValue(HtmlBasicInputRenderer.java:84) at com.sun.faces.renderkit.html_basic.HtmlBasicRenderer.getCurrentValue(HtmlBasicRenderer.java:204) at com.sun.faces.renderkit.html_basic.HtmlBasicRenderer.encodeEnd(HtmlBasicRenderer.java:171) at com.ibm.faces.renderkit.DefaultAjaxRenderer.encodeEnd(DefaultAjaxRenderer.java:83) at javax.faces.component.UIComponentBase.encodeEnd(UIComponentBase.java:762) at javax.faces.webapp.UIComponentTag.encodeEnd(UIComponentTag.java:604) at javax.faces.webapp.UIComponentTag.doEndTag(UIComponentTag.java:527) at com.sun.faces.taglib.html_basic.InputTextTag.doEndTag(InputTextTag.java:673) at com.ibm._jsp._passwordreset._jspx_meth_h_inputText_0(_passwordreset.java:133) at com.ibm._jsp._passwordreset._jspx_meth_h_form_0(_passwordreset.java:199) at com.ibm._jsp._passwordreset._jspx_meth_hx_scriptCollector_0(_passwordreset.java:227) at com.ibm._jsp._passwordreset._jspx_meth_f_view_0(_passwordreset.java:255) at com.ibm._jsp._passwordreset._jspService(_passwordreset.java:85) at com.ibm.ws.jsp.runtime.HttpJspBase.service(HttpJspBase.java:91) at javax.servlet.http.HttpServlet.service(HttpServlet.java:856) at com.ibm.ws.webcontainer.servlet.ServletWrapper.service(ServletWrapper.java:1284) at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:674) at com.ibm.wsspi.webcontainer.servlet.GenericServletWrapper.handleRequest(GenericServletWrapper.java:117) at com.ibm.ws.jsp.webcontainerext.JSPExtensionServletWrapper.handleRequest(JSPExtensionServletWrapper.java:178) at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.forward(WebAppRequestDispatcher.java:334) at com.sun.faces.context.ExternalContextImpl.dispatch(ExternalContextImpl.java:325) at com.sun.faces.application.ViewHandlerImpl.renderView(ViewHandlerImpl.java:254) at com.sun.faces.lifecycle.RenderResponsePhase.execute(RenderResponsePhase.java:87) at com.sun.faces.lifecycle.LifecycleImpl.phase(LifecycleImpl.java:220) at com.sun.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:118) at javax.faces.webapp.FacesServlet.service(FacesServlet.java:198) at com.ibm.ws.webcontainer.servlet.ServletWrapper.service(ServletWrapper.java:1284) at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:674) at com.ibm.ws.webcontainer.webapp.WebApp.handleRequest(WebApp.java:3004) at com.ibm.ws.webcontainer.webapp.WebGroup.handleRequest(WebGroup.java:221) at com.ibm.ws.webcontainer.VirtualHost.handleRequest(VirtualHost.java:210) at com.ibm.ws.webcontainer.WebContainer.handleRequest(WebContainer.java:1958) at com.ibm.ws.webcontainer.channel.WCChannelLink.ready(WCChannelLink.java:89) at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleDiscrimination(HttpInboundLink.java:472) at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleNewInformation(HttpInboundLink.java:411) at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.ready(HttpInboundLink.java:288) at com.ibm.ws.tcp.channel.impl.NewConnectionInitialReadCallback.sendToDiscriminaters(NewConnectionInitialReadCallback.java:207) at com.ibm.ws.tcp.channel.impl.NewConnectionInitialReadCallback.complete(NewConnectionInitialReadCallback.java:109) at com.ibm.ws.tcp.channel.impl.WorkQueueManager.requestComplete(WorkQueueManager.java(Compiled Code)) at com.ibm.ws.tcp.channel.impl.WorkQueueManager.attemptIO(WorkQueueManager.java(Compiled Code)) at com.ibm.ws.tcp.channel.impl.WorkQueueManager.workerRun(WorkQueueManager.java(Compiled Code)) at com.ibm.ws.tcp.channel.impl.WorkQueueManager$Worker.run(WorkQueueManager.java(Compiled Code)) at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java(Compiled Code)) --- end Original exception----
    Any Help will be appreciated. Thank you.

    sounds like your deployment isn't right - either your classpath isn't set correctly or you haven't included all the classes necessary in your deployment - or if this was working but now it's not then perhaps you removed something?

  • Using the 'java.sound.*' libraries and classes

    Hello,
    I am a complete noob to Java. So please forgive me if I seem a little stupid in the things I ask.
    I would like to know which development kit I should download to be able to gain access to the 'java.sound.*' and midi libraries and classes.
    I downloaded the Java SE 6 SDK but I could get access to these classes.
    I use JCreator as my compiler and I kept getting an error along the lines of 'java.sound.* package does not exist'. I have tried compiling the code with NetBeans and also wiuth Eclipse and I still have no luck and I get the same message. I am guessing the compiler is not the problem and it is the SDK as I can access other classes such as javax.swing and java.awt etc.
    If you could give me a link to the relevant SDK and maybe a good compiler, it would be greatly appreciated.
    Also I am using Windows XP and Windows Vista so if you could provide me with support for either of these operating systems then that would be great.
    Thank You
    Lee

    Here's the code for an SSCCE (Small Self Contained Compilable Example) of a working java sound application. If you don't provide a file name, It does expect you to have a wave file of Ballroom Blitz in your javatest directory, but doesn't everybody?
    To build and run it do:
    javac -cp . SoundPlayer.java
    java -cp . SoundPlayer  yourWaveFile.wav  
    import java.io.*;
    import javax.sound.sampled.*;
    import javax.sound.sampled.DataLine.*;
    public class SoundPlayer implements LineListener
         private float bufTime;
         private File soundFile;
         private SourceDataLine line;
         private AudioInputStream stream;
         private AudioFormat format;
         private Info info;
         private boolean opened;
         private int frameSize;
         private long frames;
         private int bufFrames;
         private int bufsize;
         private boolean running;
         private boolean shutdown;
         private long firstFrame, lastFrame;
         private float frameRate;
         private long currentFrame;
         private float currentTime;
         private Thread playThread;
         // constructor, take a path to an audio file
         public SoundPlayer(String path)
              this(path, 2);     // use 2 second buffer
         // or a path and a buffer size
         public SoundPlayer(String path, float bt)
              this(new File(path),bt);
         public SoundPlayer(File sf)
              this(sf, 2);  // use 2 second buffer
         public SoundPlayer(File sf, float bt)
              bufTime = bt;          // seconds per buffer
              soundFile = sf;
              openSound();
         private void openSound()
              System.out.println("Opening file"+soundFile.getName());
              try
                   firstFrame = 0;
                   currentFrame = 0;
                   shutdown = false;
                   running = false;
                   stream=AudioSystem.getAudioInputStream(soundFile);
                   format=stream.getFormat();
                   if(format.getEncoding() != AudioFormat.Encoding.PCM_SIGNED)
                        System.out.println("Converting Audio stream format");
                        stream = AudioSystem.getAudioInputStream(AudioFormat.Encoding.PCM_SIGNED,stream);
                        format = stream.getFormat();
                   frameSize = format.getFrameSize();
                   frames = stream.getFrameLength();
                   lastFrame = frames;
                   frameRate = format.getFrameRate();
                   bufFrames = (int)(frameRate*bufTime);
                   bufsize = frameSize * bufFrames;
                   System.out.println("frameRate="+frameRate);
                   System.out.println("frames="+frames+" frameSize="+frameSize+" bufFrames="+bufFrames+" bufsize="+bufsize);
                   info=new Info(SourceDataLine.class,format,bufsize);
                   line = (SourceDataLine)AudioSystem.getLine(info);
                   line.addLineListener(this);
                   line.open(format,bufsize);
                   opened = true;
              catch(Exception e)
                   e.printStackTrace();
         public void stop()
              System.out.println ("Stopping");
              if(running)
                   running = false;
                   shutdown = true;
                   if(playThread != null)
                        playThread.interrupt();
                        try{playThread.join();}
                        catch(Exception e){e.printStackTrace();}
              if (opened) close();
         private void close()
              System.out.println("close line");
              line.close();
              try{stream.close();}catch(Exception e){}
              line.removeLineListener(this);
              opened = false;
         // set the start and stop time
         public void setTimes(float t0, float tz)
              currentTime = t0;
              firstFrame = (long)(frameRate*t0);
              if(tz > 0)
                   lastFrame = (long)(frameRate*tz);
              else lastFrame = frames;
              if(lastFrame > frames)lastFrame = frames;
              if(firstFrame > lastFrame)firstFrame = lastFrame;
         public void playAsync(float start, float end)
              setTimes(start,end);
              playAsync();
         // play the sound asynchronously */
         public void playAsync()
              System.out.println("Play async");
              if(!opened)openSound();
              if(opened && !running)
                   playThread = new Thread(new Runnable(){public void run(){play();}});
                   playThread.start();
         public void play(float start, float end)
              setTimes(start,end);
              play();
         // play the sound in the calling thread
         public void play()
              if(!opened)openSound();
              if(opened && !running)
                   running = true;
                   int writeSize = frameSize*bufFrames/2; // amount we write at a time
                   byte buf[] = new byte[writeSize];     // our io buffer
                   int len;
                   long framesRemaining = lastFrame-firstFrame;
                   int framesRead;
                   currentFrame=firstFrame;
                   System.out.println("playing file, firstFrame="+firstFrame+" lastFrame="+lastFrame);
                   try
                        line.start();
                        if(firstFrame > 0)
                             long sa = firstFrame * frameSize;
                             System.out.println("Skipping "+firstFrame+" frames="+sa+" bytes");
                             while(sa > 0)sa -= stream.skip(sa);
                        while (running && framesRemaining > 0)
                             len = stream.read(buf,0,writeSize); // read our block
                             if(len > 0)
                                  framesRead = len/frameSize;
                                  framesRemaining -= framesRead;
                                  currentTime = currentFrame/frameRate;
                                  if(currentTime < 0)throw(new Exception("time too low"));
                                  System.out.println("time="+currentTime+" writing "+len+" bytes");
                                  line.write(buf,0,len);
                                  currentFrame+=framesRead;
                             else framesRemaining = 0;
                        if(running)
                             line.drain();                     // let it play out
                             while(line.isActive() && running)
                                  System.out.println("line active");
                                  Thread.sleep(100);
                             shutdown = true;
                        running = false;
                   catch(Exception e)
                        e.printStackTrace();
                        shutdown = true;
                        running = false;
                   if(shutdown)
                        close();
         // return current time relative to start of sound
         public float getTime()
              return ((float)line.getMicrosecondPosition())/1000000;
         // return total time
         public float getLength()
              return (float)frames / frameRate;
         // stop the sound playback, return time in seconds
         public float  pause()
              running = false;
              line.stop();
              return getTime();
         public void update(LineEvent le)
              System.out.println("Line event"+le.toString());
         // play a short simple PCM encoded clip
         public static void playShortClip(String fnm)
              java.applet.AudioClip clip=null;
              try
                   java.io.File file = new java.io.File(fnm);     // get a file for the name provided
                   if(file.exists())                    // only try to use a real file
                        clip = java.applet.Applet.newAudioClip(file.toURL()); // get the audio clip
                   else
                        System.out.println("file="+fnm+" not found");
              catch(Exception e)
                   System.out.println("Error building audio clip from file="+fnm);
                   e.printStackTrace();
              if(clip != null)     // we may not actually have a clip
                   final java.applet.AudioClip rclip = clip;
                   new Thread
                   (new Runnable()
                             public void run()
                                  rclip.play();
                   ).start();
         public boolean isOpened()
              return opened;
         public boolean isRunning()
              return running;
        public void showControls() {
            Control [] controls = line.getControls();
            for (Control c :controls) {
                System.out.println(c.toString());
        public void setGain(float gain) {
            FloatControl g = (FloatControl) line.getControl(FloatControl.Type.MASTER_GAIN);
            g.setValue(gain);
        public static void main(String [] args) {
            float gain = 0;
            String file = "c:\\javatest\\BallroomBlitz.wav";
              for(String arg : args) {
                for(int i = 0; i < arg.length(); i++) {
                    char c  = arg.charAt(i);
                    if (c == '-') {
                        gain -= 1;
                    } else if (c == '+') {
                        gain += 1;
                    } else {
                             file = arg;
            SoundPlayer sp = new SoundPlayer(file);
            sp.showControls();
            System.out.println("setting gain to " + gain);
            sp.setGain(gain);
            sp.play();
    }

  • An I18N bug from java sound should be fixed.

    When you try to list some audio related names (such as mix name, port name, control name) by using java sound api, and if the names are writtened by non-ascii character such as Chinese, you will get the strange characters, that means java sound api does not support internationalization character. Here is the sample:
    *     SystemMixerFrame.java
    * Copyright (c) 2001 - 2002 by Matthias Pfisterer
    * All rights reserved.
    * Redistribution and use in source and binary forms, with or without
    * modification, are permitted provided that the following conditions
    * are met:
    * - Redistributions of source code must retain the above copyright notice,
    * this list of conditions and the following disclaimer.
    * - Redistributions in binary form must reproduce the above copyright
    * notice, this list of conditions and the following disclaimer in the
    * documentation and/or other materials provided with the distribution.
    * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
    * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
    * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
    * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
    * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
    * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
    * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
    * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
    * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
    * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
    * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED
    * OF THE POSSIBILITY OF SUCH DAMAGE.
    import java.util.ArrayList;
    import java.util.Iterator;
    import java.util.List;
    import javax.sound.sampled.AudioSystem;
    import javax.sound.sampled.BooleanControl;
    import javax.sound.sampled.CompoundControl;
    import javax.sound.sampled.Control;
    import javax.sound.sampled.EnumControl;
    import javax.sound.sampled.FloatControl;
    import javax.sound.sampled.Line;
    import javax.sound.sampled.LineUnavailableException;
    import javax.sound.sampled.Mixer;
    import javax.sound.sampled.Port;
    IDEAS:
    - user setting tab style vs. show complete windows for multiple mixers (horicontal/vertical)
    - user setting unix style (L/R volume) vs. windows style (volume/balance)
    /**     TODO:
    public class TestSystemMixer {
         /**     TODO:
         private static final Port.Info[]     EMPTY_PORT_INFO_ARRAY = new Port.Info[0];
         public static void main(String[] args) {
              new TestSystemMixer();
              System.exit(0);
         /**     TODO:
         public TestSystemMixer()
              List portMixers = getPortMixers();
              if (portMixers.size() == 0) {
                   out("There are no mixers that support Port lines.SystemMixer: Error");
                   System.exit(1);
              Iterator iterator = portMixers.iterator();
              while (iterator.hasNext())
                   Mixer     mixer = (Mixer) iterator.next();
                   String     strMixerName = mixer.getMixerInfo().getName();
                   out("mixername:" + strMixerName);
                   createMixerPanel(mixer);
         /**     Returns the Mixers that support Port lines.
         private List getPortMixers()
              List supportingMixers = new ArrayList();
              Mixer.Info[]     aMixerInfos = AudioSystem.getMixerInfo();
              for (int i = 0; i < aMixerInfos.length; i++)
                   Mixer     mixer = AudioSystem.getMixer(aMixerInfos);
                   boolean     bSupportsPorts = arePortsSupported(mixer);
                   if (bSupportsPorts)
                        supportingMixers.add(mixer);
              return supportingMixers;
         /**     TODO:
         // should be implemented by:
         // Mixer.isLineSupported(new Line.Info(Port.class))
         private boolean arePortsSupported(Mixer mixer)
              Line.Info[]     infos;
              infos = mixer.getSourceLineInfo();
              for (int i = 0; i < infos.length; i++)
                   if (infos[i] instanceof Port.Info)
                        return true;
              infos = mixer.getTargetLineInfo();
              for (int i = 0; i < infos.length; i++)
                   if (infos[i] instanceof Port.Info)
                        return true;
              return false;
         /**     TODO:
         private void createMixerPanel(Mixer mixer)
              Port.Info[]     infosToCheck = getPortInfo(mixer);
              for (int i = 0; i < infosToCheck.length; i++)
                   Port     port = null;
                   try
                        port = (Port) mixer.getLine(infosToCheck[i]);
                        port.open();
                   catch (LineUnavailableException e)
                        e.printStackTrace();
                   if (port != null)
                        createPortPanel(port);
         /**     TODO:
         private Port.Info[] getPortInfo(Mixer mixer)
              Line.Info[]     infos;
              List portInfoList = new ArrayList();
              infos = mixer.getSourceLineInfo();
              for (int i = 0; i < infos.length; i++)
                   if (infos[i] instanceof Port.Info)
                        portInfoList.add((Port.Info) infos[i]);
              infos = mixer.getTargetLineInfo();
              for (int i = 0; i < infos.length; i++)
                   if (infos[i] instanceof Port.Info)
                        portInfoList.add((Port.Info) infos[i]);
              Port.Info[]     portInfos = (Port.Info[]) portInfoList.toArray(EMPTY_PORT_INFO_ARRAY);
              return portInfos;
         /**     TODO:
         private void createPortPanel(Port port)
              String     strPortName = ((Port.Info) port.getLineInfo()).getName();
              out("Portname:" + strPortName);
              Control[]     aControls = port.getControls();
    //          for (int i = 0; i < aControls.length; i++)
              if (aControls.length > 1) {
                   // In fact in the windows system, it named SPEAKER port, and it contains play controls.
                   out("ignore the port " + strPortName + " that contains more than one control.");
              } else {
                   // this is record control.
                   out("control:" + aControls[0].toString());
                   createControlComponent(aControls[0]);
                   if (aControls[0] instanceof FloatControl)
                   else
         /**     TODO:
         private void createControlComponent(Control control)
              if (control instanceof BooleanControl)
              String          strControlName = control.getType().toString();
              out("sub control type BooleanControl:" + strControlName);
              else if (control instanceof EnumControl)
              String     strControlName = control.getType().toString();
              out("sub control type EnumControl:" + strControlName);
              System.out.println("WARNING: EnumControl is not yet supported");
              else if (control instanceof FloatControl)
              String     strControlName = control.getType().toString();
              out("sub control type FloatControl:" + strControlName);
              else if (control instanceof CompoundControl)
              String     strControlName = control.getType().toString();
              out("sub control type CompoundControl:" + strControlName);
              Control[]     aControls = ((CompoundControl)control).getMemberControls();
              for (int i = 0; i < aControls.length; i++)
                   Control con = aControls[i];
                   if (con instanceof BooleanControl) {
                        out("sub sub control type BooleanControl:" + con.getType().toString());
                        if (strControlName.equalsIgnoreCase("Stereo Mix")) {
                             ((BooleanControl) con).setValue(true);
                   else if (con instanceof EnumControl) {
                        out("sub sub control type EnumControl:" + con.getType().toString());
                   else if (con instanceof FloatControl)
                        if (isBalanceOrPan((FloatControl) con))
                        out("sub sub control type FloatControl balance:" + con.getType().toString());
                        else
                        out("sub sub control type FloatControl pan:" + con.getType().toString());
                   else
         /** Returns whether the type of a FloatControl is BALANCE or PAN.
         private static boolean isBalanceOrPan(FloatControl control)
              Control.Type type = control.getType();
              return type.equals(FloatControl.Type.PAN) || type.equals(FloatControl.Type.BALANCE);
         private static void out(String message)
              System.out.println(message);
    /*** SystemMixerFrame.java ***/
    Compile and run the code below on non-ascii Windows OS, you will catch the problem.
    The solution I provide:
    Download the jdk 1.4.2 source, search the files named PortMixer.c && PortMixerProvider.c and replace the method "NewStringUTF" with the method below:
    jstring WindowsTojstring2( JNIEnv* env, char* str )
    jstring rtn = 0;
    int slen = strlen(str);
    unsigned short* buffer = 0;
    if( slen == 0 )
    rtn = (*env)->NewStringUTF(env,str );
    else
    int length = MultiByteToWideChar( CP_ACP, 0, (LPCSTR)str, slen, NULL, 0 );
    buffer = malloc( length*2 + 1 );
    if( MultiByteToWideChar( CP_ACP, 0, (LPCSTR)str, slen, (LPWSTR)buffer, length ) >0 )
    rtn = (*env)->NewString( env, (jchar*)buffer, length );
    if( buffer )
    free( buffer );
    return rtn;
    Rebuild jdk source code as per sun build document. Got the result files and pick up jsound.dll, replace the original jsound.dll in your JRE with the fixed file.
    Then the problem solved. I also hope sun will fix the problem in the future version of JDK.
    Or any one can help me to submit this article to the sun JDK team.
    Jiawei Zhang
    From Chinese, The city of Shanghai.
    MSN: [email protected]

    If you only wanted to get a beep you could have used Toolkit.beep
    Very simple and fast.
    Rommie.

  • Application error, "security java/lang/securityexc...

    When i try to open some applications (sensor for example), phone (nokia 6233) gives me this error:
    Application error, "security java/lang/securityexception Access denied"
    Any help?

    I installed a 3rd party app from brothersoft on my 6133.  The instructions say:
    Sound Recorder can record Sound until the free memory in the memory card is finished. The recorded music will be saved as .amr file on the memory card.
    Permissions that the user should provide to run the application:
    The permission to access the audio recorder hardware of the phone for recording.
    The permission to access the file system for storing the recorded data.
    The permission to access the file system for playing the recorded music.
    The recoded music will be saved as .amr file in the card memory.
    I'm getting the security error referenced in the thread title.  How do I go about setting permissions for accessing the recorder hardware and the file system?  The only option I see under "Options" for the application is "Application Access", but that function is greyed out.

  • Capturing audio through applet using Java Sound

    hi fellows i need ur help.
    I am working on a voice project to Capture & Play the sound using java sound API instead of JMF. I can capture , play and transmit the sound through application. It works pretty fine but when i convert it to the applet, it is not working.
    I got the full system permissions and also signed the applet for Internet Explorer. Also i packed the
    javax.sound.midi.*
    javax.sound.sampled.*
    classes in the signed cab.
    After doing all this i am getting the AudioFormat not supported exception. I changed the format and used all the combinations but still getting this error
    No line matching interface TargetDataLine supporting format PCM_SIGNED, 16000.0 Hz, 16 bit, mono, big-endian, audio data is supported.
    java.lang.IllegalArgumentException: No line matching interface TargetDataLine supporting format PCM_SIGNED, 16000.0 Hz, 16 bit, mono, big-endian, audio data is supported.
         at javax/sound/sampled/AudioSystem.getLine (AudioSystem.java:312)
         at com/vsoft/voice/VoiceRecord.run (VoiceApplet.java:93)
         at java/lang/Thread.run (Thread.java)plz help me to sort out this problem.

    plz have a look over this problem

  • A FIX for error message: When I try to open Snood (it's a game) I get this message.  Not enough memory {Error # :: 0, in sound.cp@line 101  Can you help?

    After years of playing Snood, w/o problems, I started getting this error message, on my iMac, OS 10.5.8,
    with 4 GB of memory when opening Snood:  Not enough memory {Error # :: 0, in sound.cp@line 101
    My MacBook Pro w. Mac OS 10.6.8 did not have this problem.
    Initially I thought that Snood raised its minimum requirement to Mac OS 10.6.
    I had several correspondences with Snood. Their tech support is great. Quick and thorough responses.
    They thought the issue was in Mac's system preferences/ Sound. It was.
    I didn't realize that my sound input and output devices were gone.
    The fix was resetting the PRAM. I found this advice on MacFixIt.com.
    MacFixIt help with volume:   http://reviews.cnet.com/8301-13727_7-10415659-263.html
    Resetting the PRAM is on Apple support:   http://support.apple.com/kb/HT1379
    My sound (music!) is back, along with Snood. So glad I reset the PRAM before reinstalling the OS software!
    Thank you to Snood, MacFixIt and Apple.
    Happy new year all!

    Good work, nice post/tip, thanks!

  • Error starting java in RedHat Enterprise ES v3

    Hello all. I'm posting hoping someone has run into this before and might be able to help me.
    We've set up a number of boxes with Redhat Enterprise ES v3, and upgraded the kernel from the stock RedHat 2.4.21 to 2.4.26 because we required reiserfs support (no idea why it isn't bundled from RedHat).
    We are using j2sdk1.4.2_02.
    Once the kernel was upgraded, I tried to run java and we get a strange error. Java runs fine with the stock kernel, but not with the new one.
    At this point in time, I'm inclined to think I neglected to enable an option in the kernel configuration, but I went back and wasn't able to find anything.
    Any idea what could be causing this issue? The complete error is below.
    Thank you in advance
    -Paul
    An unexpected exception has been detected in native code outside the VM.
    Unexpected Signal : 11 occurred at PC=0x0
    Function=[Unknown.]
    Library=(N/A)
    NOTE: We are unable to locate the function name symbol for the error
    just occurred. Please refer to release documentation for possible
    reason and solutions.
    Current Java thread:
    Dynamic libraries:
    08048000-0804e000 r-xp 00000000 03:03 7962746 /usr/java/j2sdk1.4.2_02/bin/jav
    a
    0804e000-0804f000 rw-p 00005000 03:03 7962746 /usr/java/j2sdk1.4.2_02/bin/jav
    a
    40000000-40015000 r-xp 00000000 03:03 524292 /lib/ld-2.3.2.so
    40015000-40016000 rw-p 00014000 03:03 524292 /lib/ld-2.3.2.so
    40017000-4001f000 r-xp 00000000 03:03 8274108 /usr/java/j2sdk1.4.2_02/jre/lib
    /i386/native_threads/libhpi.so
    4001f000-40020000 rw-p 00007000 03:03 8274108 /usr/java/j2sdk1.4.2_02/jre/lib
    /i386/native_threads/libhpi.so
    40020000-4002d000 r-xp 00000000 03:03 2408456 /lib/tls/libpthread-0.60.so
    4002d000-4002e000 rw-p 0000c000 03:03 2408456 /lib/tls/libpthread-0.60.so
    40030000-40032000 r-xp 00000000 03:03 524305 /lib/libdl-2.3.2.so
    40032000-40033000 rw-p 00001000 03:03 524305 /lib/libdl-2.3.2.so
    40033000-40165000 r-xp 00000000 03:03 2408452 /lib/tls/libc-2.3.2.so
    40165000-40168000 rw-p 00131000 03:03 2408452 /lib/tls/libc-2.3.2.so
    4016c000-40566000 r-xp 00000000 03:03 7667771 /usr/java/j2sdk1.4.2_02/jre/lib
    /i386/client/libjvm.so
    40566000-40582000 rw-p 003f9000 03:03 7667771 /usr/java/j2sdk1.4.2_02/jre/lib
    /i386/client/libjvm.so
    40594000-405a6000 r-xp 00000000 03:03 524309 /lib/libnsl-2.3.2.so
    405a6000-405a7000 rw-p 00011000 03:03 524309 /lib/libnsl-2.3.2.so
    405a9000-405ca000 r-xp 00000000 03:03 2408454 /lib/tls/libm-2.3.2.so
    405ca000-405cb000 rw-p 00020000 03:03 2408454 /lib/tls/libm-2.3.2.so
    405cb000-405cf000 rw-s 00000000 03:03 5292244 /tmp/hsperfdata_root/7828
    405d4000-405df000 r-xp 00000000 03:03 524325 /lib/libnss_files-2.3.2.so
    405df000-405e0000 rw-p 0000a000 03:03 524325 /lib/libnss_files-2.3.2.so
    405e0000-405f0000 r-xp 00000000 03:03 7045311 /usr/java/j2sdk1.4.2_02/jre/lib
    /i386/libverify.so
    405f0000-405f2000 rw-p 0000f000 03:03 7045311 /usr/java/j2sdk1.4.2_02/jre/lib
    /i386/libverify.so
    405f2000-40612000 r-xp 00000000 03:03 7045297 /usr/java/j2sdk1.4.2_02/jre/lib
    /i386/libjava.so
    40612000-40614000 rw-p 0001f000 03:03 7045297 /usr/java/j2sdk1.4.2_02/jre/lib
    /i386/libjava.so
    40614000-40628000 r-xp 00000000 03:03 7045312 /usr/java/j2sdk1.4.2_02/jre/lib
    /i386/libzip.so
    40628000-4062b000 rw-p 00013000 03:03 7045312 /usr/java/j2sdk1.4.2_02/jre/lib
    /i386/libzip.so
    4062b000-41fc3000 r--s 00000000 03:03 3768491 /usr/java/j2sdk1.4.2_02/jre/lib
    /rt.jar
    4200d000-42023000 r--s 00000000 03:03 3768490 /usr/java/j2sdk1.4.2_02/jre/lib
    /sunrsasign.jar
    42023000-420fe000 r--s 00000000 03:03 3768489 /usr/java/j2sdk1.4.2_02/jre/lib
    /jsse.jar
    420fe000-4210f000 r--s 00000000 03:03 3768481 /usr/java/j2sdk1.4.2_02/jre/lib
    /jce.jar
    4210f000-42668000 r--s 00000000 03:03 3768482 /usr/java/j2sdk1.4.2_02/jre/lib
    /charsets.jar
    Heap at VM Abort:
    Heap
    def new generation total 576K, used 0K [0x44710000, 0x447b0000, 0x44bf0000)
    eden space 512K, 0% used [0x44710000, 0x44710048, 0x44790000)
    from space 64K, 0% used [0x44790000, 0x44790000, 0x447a0000)
    to space 64K, 0% used [0x447a0000, 0x447a0000, 0x447b0000)
    tenured generation total 1408K, used 0K [0x44bf0000, 0x44d50000, 0x48710000)
    the space 1408K, 0% used [0x44bf0000, 0x44bf0000, 0x44bf0200, 0x44d50000)
    compacting perm gen total 4096K, used 276K [0x48710000, 0x48b10000, 0x4c710000
    the space 4096K, 6% used [0x48710000, 0x48755070, 0x48755200, 0x48b10000)
    Local Time = Sat Jun 26 13:20:19 2004
    Elapsed Time = 0
    # The exception above was detected in native code outside the VM
    # Java VM: Java HotSpot(TM) Client VM (1.4.2_02-b03 mixed mode)

    Hi ditg.
    I have no idea what was causing the problem on 2.4.26, but at this point in time, I'm almost 100% sure it's a kernel-specific issue.
    The workaround I came up with was rebuild the 2.4.21 kernel using the RedHat sources, disabling all the non-necessary modules and basically make it as slim as possible.
    Once we successfully recompiled 2.4.21, j2sdk1.4.2.02/3/4 runs fine.
    Hope this helps....
    -Paul

  • I am getting Error! java.sql.SQLException:General error

    hi every body,
    I struck with this error , can any one suggest in solving this.
    I had a table in oracledatabase ,i have successfully created a table and inserted clob column with an attachment like xxx.txt.
    table format----> id and text columns
    Now my question is to retrieve that data and store it in local disk i am getting this error
    import java.io.*;
    import java.sql.*;
    //import java.sql.SQLException;
    public class Cread {
    public static void main(String[] args) throws ClassNotFoundException,IOException,SQLException {
    try {
    Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
    Connection cn=DriverManager.getConnection("jdbc:odbc:sivadsn","scott","tiger");
    Statement s = cn.createStatement();
    ResultSet rs=s.executeQuery("Select text from ram where id=10");
    if(rs.next()){
    FileOutputStream file=new FileOutputStream("c:/store.txt");
    InputStream fin=rs.getBinaryStream(1);
    int c;
    while((c=fin.read())!=-1){
    file.write(c);
    fin.close();
    s.close();
    rs.close();
    catch(IOException e){
    e.printStackTrace();
    System.out.println("Err:"+e);
    I am getting the error as
    java.sql.SQLException: General error
    at sun.jdbc.odbc.JdbcOdbc.createSQLException(Unknown Source)
    at sun.jdbc.odbc.JdbcOdbc.standardError(Unknown Source)
    at sun.jdbc.odbc.JdbcOdbc.SQLExecDirect(Unknown Source)
    at sun.jdbc.odbc.JdbcOdbcStatement.execute(Unknown Source)
    at sun.jdbc.odbc.JdbcOdbcStatement.executeQuery(Unknown Source)Error! java.sql.SQLException: General error
    at attach.Clobread.main(Clobread.java:30)

    That usually means something is wrong with the syntax of your sql.
    As a guess 'text' is probably a keyword and shouldn't be used as a field name. It is possible that the same is true for 'id'

  • Error(5): java.util.zip.ZipException: invalid entry size (expected 2875 but

    Hi all!
    I'm getting this error when I try to execute my application in JDeveloper: Error(5): java.util.zip.ZipException: invalid entry size (expected 2875 but got 2845 bytes)
    This started to happen after I had checkout my application to CVSNT.
    Any help?
    P.S. I'm using JDeveloper 10.1.3 with CVSNT 2.5

    My cvswrappers file (CVSNT):
    *.cab -kb
    *.class -kb
    *.doc -kb
    *.dll -kb
    *.ear -kb
    *.exe -kb
    *.exp -kb
    *.fla -kb
    *.gif -kb
    *.gz -kb
    *.jar -kb
    *.jpg -kb
    *.jpeg -kb
    *.lib -kb
    *.msi -kb
    *.mso -kb
    *.pdf -kb
    *.pfw -kb
    *.png -kb
    *.ppt -kb
    *.sit -kb
    *.swf -kb
    *.tar -kb
    *.tlb -kb
    *.vsd -kb
    *.xls -kb
    *.war -kb
    *.wmz -kb
    *.zip -kb Via Tortoise client I can add and commit zip (jar) files in binary format and everything is OK.
    If I do that via Jdev, anybody who checkout that module from cvs have zip exception, because JDev didnt sent in binary format. How to setup that?
    Thanx
    Message was edited by:
    vpetreski

  • Error(7): java.util.zip.ZipException: invalid entry size (expected 813 but

    Hi All,
    Error(7): java.util.zip.ZipException: invalid entry size (expected 813 but got 817 bytes)
    Today I opened my working project in Jdeveloper 10.1.3 version and as I compile the project, it gives me this error in all Jsf - Jsp pages.
    The line that it shows the above error in my pages is follows.
    <%@ taglib uri="http://java.sun.com/jsf/html" prefix="h"%>
    Any idea ? Till yesterday, I never got this error and all of sudden it started showing up.
    Your help appreciated.
    thanks,
    pp

    And just to add, nothing got checked out from repository (I mean CVS etc).
    I have this project and Jdev on my windows laptop. I just opened it and started getting this strange error. any idea ?

  • Error: The Java Runtime in use does not contain a suitable JAXP feature

    Hi,
    I'm trying to get Eclipse TPTP to work. One of the steps I need to execute is to run a setConfig.bat file. When I ran it, I got the following error:
    ERROR: The Java Runtime in use does not contain a suitable JAXP feature
    RESOLUTION: Use a JRE which supports the JAXP featureI use Eclipse Europa, and it is using my JDK (actually JRE) 1.6.0_05. That should mean I have JAXP in my JRE (which is confirmed when I search on JAXP from the directory C:\Program Files\Java containing jdk1.6.5_05 and jre1.6.5_05 directories).
    Is there something extra I need to do to let Eclipse and TPTP find my JAXP classes?
    TIA,
    Abel

    Hi,
    Even i am getting the same error but i use JRE 1.5.0_14. please let me know if you happen to resolve this.
    Thanks in Advance,
    Sai

  • Simple Java Sound Question...

    Can I draw waveforms while capturing data? If yes, how. If no, why.
    Thanks. I need the answer ASAP, please help.

    Hi nfactorial,
    Can I draw waveforms while capturing data?If you would like to do that in Java you would need to know about how to use the Java language in general and especially about the Java Sound and Java2D APIs.
    If yes, how.It would be too much to explain to answer such a general question. A general answer is, you need to use the Java Sound API to capture the data for which a waveform should be drawn. The Sound API delivers data as a stream of bytes typically encoded in pulse coded modulation (PCM) format. The data stream has digital samples each representing a level of sound pressure for a certain point in time. The stream of samples in the amplitude/time domain need to be transformed to a spectrum of samples in the amplitude/frequency domain, i.e. a number of PCM samples need to be mapped to the frequencies that should be displayed. This is done with the fast fourier transformation algorithm. Each set of amplitude/frequency values can then be displayed as a waveform by using some line drawing logic. The entire process would need to run constantly, i.e. as bytes are received from the sound data stream transformation and drawing is triggered.
    Related readings:
    Java Tutorial
    http://java.sun.com/docs/books/tutorial/
    Java Sound Documentation
    http://java.sun.com/j2se/1.5.0/docs/guide/sound/index.html
    Java Sound API Programmer's Guide
    http://java.sun.com/j2se/1.5.0/docs/guide/sound/programmer_guide/contents.html
    Java Sound Resources
    http.//www.jsresources.org
    Java 2D Graphics Tutorial
    http://java.sun.com/docs/books/tutorial/2d/index.html
    Wikipedia on fast fourier transformation
    http://en.wikipedia.org/wiki/Fast_fourier_transform
    HTH
    Ulrich

  • Java Plug in fatel Error The java Runtime Environment cannot be loaded from

    Java Plug in fatel Error The java Runtime Environment cannot be loaded from <\bin\server\jvm.dll>
    files are left behind when you uninstall Java from Windows XP.
    Directory of C:\Documents and Settings\user1\.java
    10/14/2004 06:02 PM <DIR> .
    10/14/2004 06:02 PM <DIR> ..
    03/07/2005 07:10 PM 32 jpicerts130_02
    09/19/2004 04:37 PM 32 jpicerts141_02
    09/19/2004 04:37 PM 32 jpihttpscerts141_02
    03/07/2005 07:10 PM 549 properties130_02
    09/19/2004 04:37 PM 383 properties141_02
    5 File(s) 1,028 bytes

    How do i fix it

  • Oracle error 1403:java.sql.SQLException: ORA-01403: no data found ORA-06512

    My customer has an issue, and error message as below:
    <PRE>Oracle error 1403: java.sql.SQLException: ORA-01403: no data found ORA-06512:
    at line 1 has been detected in FND_SESSION_MANAGEMENT.CHECK_SESSION. Your
    session is no longer valid.</PRE>
    Servlet error: An exception occurred. The current application deployment descriptors do not allow for including it in this response. Please consult the application log for details.
    And customer’s statement is: Upgrade from EBS 11.5.10 to 12.1.3. Login the EBS, open any forms and put it in idle. Then refresh the form, error happens
    Then, I checked ISP, and found two notes:
    Note 1284094.1: Web ADI Journal Upload Errors With ORA-01403 No Data Found ORA-06512 At Line Has Been Detected In FND_SESSION_MANAGEMENT.CHECK_SESSION.Your Session Is No Longer Valid (Doc ID 1284094.1)
    Note 1319380.1: Webadi Gl Journal Posting Errors After Atg R12.1.3 (Doc ID 1319380.1)
    But these two notes are both WebADI.
    Following is the data collection from customer:
    1. Run UNIX command to check .class file version:
    strings $JAVA_TOP/oracle/apps/bne/utilities/BneViewerUtils.class | grep Header--> S$Header: BneViewerUtils.java 120.33.12010000.17 2010/11/21 22:19:58 amgonzal s$
    2. Run SQL to check you patch level:
    SELECT * FROM fnd_product_installations WHERE patch_level LIKE '%BNE%';--> R12.BNE.B.3
    3. Run SQL to check patch '9940148' applied or not:
    SELECT * FROM ad_bugs ad WHERE ad.bug_number = '9940148';--> No Rows returned
    4. Run SQL to check patch '9785477' applied or not:
    SELECT * FROM ad_bugs WHERE bug_number in ('9785477');-->
    BUG_ID APPLICATION_SHORT_NAME BUG_NUMBER CREATION_DATE ARU_RELEASE_NAME CREATED_BY LAST_UPDATE_DATE LAST_UPDATED_BY TRACKABLE_ENTITY_ABBR BASELINE_NAME GENERIC_PATCH LANGUAGE
    576982 11839583 2011/8/7 上午 08:20:36 R12 5 2011/8/7 上午 08:20:36 5 pjt B n US
    516492 9785477 2011/6/12 上午 11:42:45 R12 5 2011/6/12 上午 11:42:45 5 bne B n US
    546109 9785477 2011/6/12 下午 01:17:41 R12 5 2011/6/12 下午 01:17:41 5 bne B n ZHT
    5. Run SQL to check the status of object ‘FND_SESSION_MANAGEMENT’
    SELECT * FROM dba_objects do WHERE do.object_name = 'FND_SESSION_MANAGEMENT';-->
    OWNER OBJECT_NAME SUBOBJECT_NAME OBJECT_ID DATA_OBJECT_ID OBJECT_TYPE CREATED LAST_DDL_TIME TIMESTAMP STATUS TEMPORARY GENERATED SECONDARY NAMESPACE EDITION_NAME
    APPS FND_SESSION_MANAGEMENT 219425 PACKAGE 2004/10/30 下午 01:52:35 2011/8/7 上午 08:18:39 2011-08-07:08:18:26 VALID N N N 1
    APPS FND_SESSION_MANAGEMENT 226815 PACKAGE BODY 2004/10/31 上午 01:05:40 2011/8/7 上午 08:18:54 2011-08-07:08:18:27 VALID N N N 2
    So, my question is: Customer’s BneViewerUtils.java version is already 120.33.12010000.17, which greater than 120.33.12010000.14. Is there any others solutions for this issue? Does customer still need to apply patch '9940148' based on action plan of
    Note 1284094.1: Web ADI Journal Upload Errors With ORA-01403 No Data Found ORA-06512 At Line Has Been Detected In FND_SESSION_MANAGEMENT.CHECK_SESSION.Your Session Is No Longer Valid?
    Customer's EBS version is 12.1.3; OS is HP-UX PA-RISC (64-bit); DB is 11.2.0.2.
    Thanks,
    Jackie

    And customer’s statement is: Upgrade from EBS 11.5.10 to 12.1.3. Login the EBS, open any forms and put it in idle. Then refresh the form, error happens
    Idle for how long? Is the issue with all sessions?
    Please see these docs/links
    User Sessions Get Timed Out Before Idle Time Parameter Values Are Reached [ID 1306678.1]
    https://forums.oracle.com/forums/search.jspa?threadID=&q=Timeout+AND+R12&objID=c3&dateRange=all&userID=&numResults=15&rankBy=10001
    Then, I checked ISP, and found two notes:
    Note 1284094.1: Web ADI Journal Upload Errors With ORA-01403 No Data Found ORA-06512 At Line Has Been Detected In FND_SESSION_MANAGEMENT.CHECK_SESSION.Your Session Is No Longer Valid (Doc ID 1284094.1)
    Note 1319380.1: Webadi Gl Journal Posting Errors After Atg R12.1.3 (Doc ID 1319380.1)
    But these two notes are both WebADI.Can you find any details about the error in Apache log files and in the application.log file?
    Any errors in the database log file?
    So, my question is: Customer’s BneViewerUtils.java version is already 120.33.12010000.17, which greater than 120.33.12010000.14. Is there any others solutions for this issue? No.
    Does customer still need to apply patch '9940148' based on action plan ofIf the issue not with Web ADI, then ignore this patch. However, if you use Web ADI you could query AD_BUGS table and verify if you have the patch applied.
    Note 1284094.1: Web ADI Journal Upload Errors With ORA-01403 No Data Found ORA-06512 At Line Has Been Detected In FND_SESSION_MANAGEMENT.CHECK_SESSION.Your Session Is No Longer Valid?
    Customer's EBS version is 12.1.3; OS is HP-UX PA-RISC (64-bit); DB is 11.2.0.2.If you could not find any details in the logs, please enable debug as per (R12, 12.1 - How To Enable and Collect Debug for HTTP, OC4J and OPMN [ID 422419.1]).
    Thanks,
    Hussein

Maybe you are looking for