Java.lang.NoClassDefFoundError: Simulation Help please!

java.lang.NoClassDefFoundError: Simulation
     at SimulationController.setEnv(SimulationController.java)
     at EnvironmentController.setEnv(EnvironmentController.java)
     at EnvironmentController.openFile(EnvironmentController.java)
     at MBSGUIFrame$1.actionPerformed(MBSGUIFrame.java)
     at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:1786)
     at javax.swing.AbstractButton$ForwardActionEvents.actionPerformed(AbstractButton.java:1839)
     at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:420)
     at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:258)
     at javax.swing.AbstractButton.doClick(AbstractButton.java:289)
     at javax.swing.plaf.basic.BasicMenuItemUI.doClick(BasicMenuItemUI.java:1113)
     at javax.swing.plaf.basic.BasicMenuItemUI$MouseInputHandler.mouseReleased(BasicMenuItemUI.java:943)
     at java.awt.Component.processMouseEvent(Component.java:5100)
     at java.awt.Component.processEvent(Component.java:4897)
     at java.awt.Container.processEvent(Container.java:1569)
     at java.awt.Component.dispatchEventImpl(Component.java:3615)
     at java.awt.Container.dispatchEventImpl(Container.java:1627)
     at java.awt.Component.dispatchEvent(Component.java:3477)
     at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:3483)
     at java.awt.LightweightDispatcher.processMouseEvent(Container.java:3198)
     at java.awt.LightweightDispatcher.dispatchEvent(Container.java:3128)
     at java.awt.Container.dispatchEventImpl(Container.java:1613)
     at java.awt.Window.dispatchEventImpl(Window.java:1606)
     at java.awt.Component.dispatchEvent(Component.java:3477)
     at java.awt.EventQueue.dispatchEvent(EventQueue.java:480)
     at java.awt.EventDispatchThread.pumpOneEventForHierarchy(EventDispatchThread.java:201)
     at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:151)
     at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:145)
     at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:137)
     at java.awt.EventDispatchThread.run(EventDispatchThread.java:100)
Exit code: 0
No Errors
This occurs when I try to run a data file through a case study program that I need for my examinations. I'm using RealJ 3.51, with SDK 1.4.2_09 The case study launches fine, and when I open the .dat file, I can see the fish which should begin to move, but that is when I get that error.

Trying to guess... Does that class have a package or something?

Similar Messages

  • Argh! "java.lang.NoClassDefFoundError"! help!

    I am a student and only just started programming in Java. When I installed the SDK on my home computer i discovered that everytime i try and run a program i have written, no matter how basic, i get a "java.lang.NoClassDefFoundError". I did a search on the forum and found lots of stuff about something called classpath, but i have no idea what it is or how to do it, despite the explanations ive read. If someone could please take me through it step by step id be VERY greatful.
    I'm running it on Windows XP home edition.
    Thanks alot
    Jon

    I tried the tutorial you showed me, thanks. However, it doesnt seem to have worked, when i did the "set CLASSTEST=" in the directory i was in then it worked, but only temporarily. But when I tried changing the Path variable in Environment Variables (Control Panel\System --> Advanced --> Environment Variables, it didnt seems to work. I added "C:\j2sdk1.4.2_02\bin" to both the user variables and system variables.
    Anyway, this is what I tried, from the beginning...
    I wrote the code in TextPad, the code is as follows -
    public class HelloWorld {
    public static void main( String[] args ) {
    System.out.println( "hello world" );
    (as i understand, it couldnt be any simpler!)
    I then compiled this in TextPad and got no errors.
    I then tried then run it, also through TextPad (Tools --> Run Java Application) and got this error (word for word) -
    Exception in thread "main" java.lang.NoClassDefFoundError: HelloWorld
    Press any key to continue . . .
    I also tried running it from the command prompt and just got the same error, even when i switched to the right directory (C:\Documents and Settings\Jon\Desktop\Uni_stuff). The commands i entered were "java HelloWorld".
    If anyone can help me with this, id be greatful as its getting pretty urgent.
    Thanks
    Jon Britton

  • ERROR: java/lang/NoClassDefFoundError. HELP!!!

    Hi all, can any one tell me what's wrong with my program that runs fine in JavaONEStudio5, but i find following error message when i run it in WTK21:
    Project "readWriteRights" loaded
    Project settings saved
    Building "readWriteRights"
    Build complete
    Running with storage root DefaultColorPhone
    Uncaught exception java/lang/NoClassDefFoundError: ReadWriteRights.
    Here is my simple program:
    * readWriteRights.java
    * A simple application program to read a text file
    * and store it's content into a Record Store.
    * the data is read from the Record Store for verification
    * Created on 2004/4/8 2:29am
    import javax.microedition.midlet.*;
    import javax.microedition.lcdui.*;
    import javax.microedition.io.*;
    import javax.microedition.rms.*;
    import java.io.*;
    public class readWriteRights extends MIDlet {
    public readWriteRights() { } // constructor
    public void startApp() throws MIDletStateChangeException {
         String fileName = "origin.drm";
         String field[] = new String [] {"","","","","","","",""};  // Total 8 constraints in the file
         int i = 0;
         // retrieve the contents of a resource file
         System.out.println("Retrieving the resource file - readme.txt");
         System.out.println("--------------------------------------------");
         InputStream is = this.getClass().getResourceAsStream(fileName);
         try {
              if ( is != null ) {
                   int ch = is.read();
                   while ( ch != -1) {
                   // print out the contents of the readme file
                   System.out.print((char) ch);
                        // temp = (temp-10)*2;   // decoding
                        if (ch == 10) { i++; } //skip it if the character is \n
                        else
                             field[i] += (char)ch;
                        if(i >= field.length)
                        { ch = -1;}
                        else{ ch = is.read();}
                   is.close();
              } catch (IOException e) {
                   System.out.println(e);
         // Write to a record store
         String rs_Name = "db1";
         RecordStore rs = null;
         try {
                     if ( exist(rs_Name) == true) {
              RecordStore.deleteRecordStore(rs_Name);
                 }  // check and delete existing Record Store
              rs = RecordStore.openRecordStore(rs_Name,true);
              System.out.println("Record Store "+rs_Name+" is opened.");
         catch(Exception e){
              System.out.println("Error: "+e.getMessage());
         finally{
              //* write records
              for (int j = 0; j < field.length; j++)
                   byte[] rec = field[j].getBytes();
                   //close the record store
                   try {
                        rs.addRecord(rec,0,rec.length);
                        System.out.println((j+1) +" record is added to db1");
                        System.out.println("Record: "+field[j]);
                   catch (Exception e){System.out.println("Error: "+e.getMessage());}
              System.out.println("Write reord completed.");
              //* read records
              try {
                   int len =50;
                            byte[] recData = new byte[len];
                            System.out.println("The data read from Record Store.");
                   for (int k=1; k <= rs.getNumRecords(); k++)
                        len = rs.getRecord(k, recData, 0);
                        System.out.println("Record #"+k+": "+new String(recData, 0, len));
                        System.out.println("---------------------------------------------------");
              catch (Exception e){System.out.println("Error2: "+e.getMessage());     }
              // * close record Store
              try {
                   rs.closeRecordStore();
                   System.out.println("record store db1 is closed");
              catch (Exception e){System.out.println("Error: "+e.getMessage());}
    destroyApp(true);
    notifyDestroyed();
    * The method to check if the Record Store existed or not
         public boolean exist(String recordStoreName) {
              boolean existF=true;
              RecordStore rs=null;
              if(recordStoreName.length()>32) return false;
                   try {
                        rs=RecordStore.openRecordStore(recordStoreName,false);
                   catch(RecordStoreNotFoundException e) {existF=false;}
                   catch(Exception e){}
                   finally{
                             try{
                                  rs.closeRecordStore();
                             }catch(Exception e){}
              return existF;
    } // end of check Record Store existance method          
    * Pause the MIDlet
    public void pauseApp() { }
    * Called by the framework before the application is unloaded
    public void destroyApp(boolean unconditional) { }
    }

    I doubt that the error is caused by " java.io.* " which is not included in MIDP so that my program cannot run in WTK21.. is that true?
    if yes, what can I do with it because I have to run it in WTK21 for demonstration. thx!!!!!

  • Java.lang.NoClassDefFoundError when running DBCA after fresh install

    Hello there.
    I have just installed Oracle 9i on a new server, since we are moving our database server from one machine to the other, and after going through the installation without any problems DBCA was going to run but I have got the following error message:
    Exception in thread "main" java.lang.NoClassDefFoundError: oracle/help/Help
    at oracle.sysman.assistants.dbca.ui.UIHost.initializeHelp(UIHost.java:24
    5)
    at oracle.sysman.assistants.dbca.ui.UIHost.initialize(UIHost.java:228)
    at oracle.sysman.assistants.dbca.Dbca.execute(Dbca.java:96)
    at oracle.sysman.assistants.dbca.Dbca.main(Dbca.java:161)
    I have checked the CLASSPATH, which currently is:
    "C:\Program Files\Oracle\jre\1.1.8\lib\rt.jar;C:\Program Files\Oracle\jre\1.1.8\lib\i18n.jar;%ORACLE_HOME%\assistants\dbca\jlib\dbca.jar;%ORACLE_HOME%\assistants\jlib\assistantsCommon.jar;%ORACLE_HOME%\jlib\ewt3.jar;%ORACLE_HOME%\jlib\ewtcompat-3_3_15.jar;%ORACLE_HOME%\jlib\share.jar;%ORACLE_HOME%\jlib\swingall-1_1_1.jar;%ORACLE_HOME%\jlib\oracle_ice5.jar;%ORACLE_HOME%\jlib\help3.jar;%ORACLE_HOME%\jlib\kodiak.jar;%ORACLE_HOME%\lib\xmlparserv2.jar;%ORACLE_HOME%\jlib\gss-1_1.zip;%ORACLE_HOME%\classes;%ORACLE_HOME%\jlib\oembase-9_2_0.jar;%ORACLE_HOME%\jlib\srvm.jar;%ORACLE_HOME%\jdbc\lib\classes111.zip;%ORACLE_HOME%\jlib\netcfg.jar;%ORACLE_HOME%\lib\vbjorb.jar;%ORACLE_HOME%\lib\vbjtools.jar;%ORACLE_HOME%\lib\vbjapp.jar;%ORACLE_OEM_CLASSPATH%"
    If you could please help I would appreciate it.
    Kind regards.

    Hello, rajeysh.
    Thank you for your reply, I have tried this method but it did not work, the problem remains the same.
    Please notice that with the reference you've quoted the error is java.lang.NoClassDefFoundError: oracle/sysman/emSDK/common/nls/MessageBundle while mine reports the error java.lang.NoClassDefFoundError: oracle/help/Help.
    So, if you have any other ideas I would appreciate it.
    Kind regards.

  • Oracle Project - Gantt Chart probem java.lang.NoClassDefFoundError

    Hi all,
    I have and apps11i instance (11.5.10.2) in OEL 5 x86 and DB 10g R2
    Patch set level is as per Software Updates for +Oracle Projects Rollup Patch 4 for Oracle Projects Family Pack M (11i.PJ_PF.M)[Article ID 423428.1+
    When radio button Gantt chart view is selected in Workplan tab the following error is shown
    *JSP Error:*
    *Request URI:/OA_HTML/OA.jsp*
    *Exception:*
    *java.lang.NoClassDefFoundError*
    Any help is highly appriciated
    Thanks in advance and regards,
    Soni                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

    Soni wrote:
    Hi all,
    I have and apps11i instance (11.5.10.2) in OEL 5 x86 and DB 10g R2
    Patch set level is as per Software Updates for +Oracle Projects Rollup Patch 4 for Oracle Projects Family Pack M (11i.PJ_PF.M)[Article ID 423428.1+
    When radio button Gantt chart view is selected in Workplan tab the following error is shown
    *JSP Error:*
    *Request URI:/OA_HTML/OA.jsp*
    *Exception:*
    *java.lang.NoClassDefFoundError*
    Any help is highly appriciated
    Thanks in advance and regards,
    Soni
    Please see (Receive Error When Attempting To Open A Work Plan Gantt Chart View [ID 306413.1).Thanks,
    Hussein

  • Please HELP me with installation - java.lang.noclassdeffounderror:

    Please Help! For school we need to install JAVA. I installed JDK 5.0 and id did not work. I got exception in thread "main" java.lang.noclassdeffounderror: hello. I was using Texpad to write, compile, and run it. In short I deleted all JAVA 5.0 using My Computer program removal. I installed JAVA 1.4..2_10 and I am still getting that same error. I want the JAVA 1.4..2_10 to be installed and not JAVA.5.0.
    My System Variable CLASSPATH still shows C:\Program Files\Java\jre1.5.0_03\lib\ext\QTJava.zip. My System Variable PATH has nothing as far as JAVA in it. MY PATHEXT has JS and JSE amoung other things in it. My System Variable QTJAVA still has Files\Java\jre1.5.0_03\lib\ext\QTJava.zip in it.
    Please tell me step-by-step how I can fix this. I never updated these variables before. What do I need to type and where? What do I need to get rid of or change?
    PLEASE HELP!
    Thanks,
    Jim

    I left my System variable classpath --> C:\Program Files\Java\jre1.5.0_03\lib\ext\QTJava.zip I left my QT JAVA --> C:\Program Files\Java\jre1.5.0_03\lib\ext\QTJava.zip I added Path --> ;C:\j2sdk1.4.2_10\bin and then restarted my computer. I added hello file in C:\j2sdk1.4.2_10\bin and tried to compile it under a new name and it would not compile. it gave me the error below. I was able to compile other java program in my other folder in a different directory. I am still getting the same error messages/ Anything else I should try? IS there anyplace or person I can call who would come and fix this? Something is wrong. This should not be giving me this much trouble. All The Java directions on other websites tell me to do different things. I am so confused... please help.
    I get this during the compilenow:
    javac: invalid flag: C:\j2sdk1.4.2_10\bin\helloa.txt
    Usage: javac <options> <source files>
    where possible options include:
    -g Generate all debugging info
    -g:none Generate no debugging info
    -g:{lines,vars,source} Generate only some debugging info
    -nowarn Generate no warnings
    -verbose Output messages about what the compiler is doing
    -deprecation Output source locations where deprecated APIs are used
    -classpath <path> Specify where to find user class files
    -sourcepath <path> Specify where to find input source files
    -bootclasspath <path> Override location of bootstrap class files
    -extdirs <dirs> Override location of installed extensions
    -d <directory> Specify where to place generated class files
    -encoding <encoding> Specify character encoding used by source files
    -source <release> Provide source compatibility with specified release
    -target <release> Generate class files for specific VM version
    -help Print a synopsis of standard options
    Tool completed with exit code 2
    Jim
    If you can fix this I will give you 14 points. I hope it is enough. I just want this to work for school.

  • Java.lang.NoClassDefFoundError . Please help

    Hi everyone!
    I have this problem...i create a small java program, like "hello world". It is ok to compile and run it. The directory structure is as follows:
    /some/files/mypackage/myclass.java
    if i put in my source pacake mypackage/myclass, then i can compile the program, but when i try to run it i get this error:
    java.lang.NoClassDefFoundError
    Exception in thread "main" java.lang.NoClassDefFoundError: myclass (wrong name: mypackage/myclass)
    Thanks!!!

    You can always search the forum for answers - just put "wrong name" in the search box.
    In your case, you entered "java myclass" but the class that the jvm found was named mypackage/myclass. In other words, the myclass class is defined to be in the mypackage package so the fully qualified name of the class is mypackage/myclass (or mypackage.myclass). Your command needs to be "java mypackage/myclass" Most likely, you need to "cd /some/files/" before entering the command to run it.

  • HELP:: jsse1.0.3 problem with jdk1.3.1(java.lang.NoClassDefFoundError)

    Hi,
    I am now working with jsse1.0.3 and jdk1.3.1(I can not use the new jdk version, because the system I developed is based on jdk1.3.1). what makes me strange is that I can compile my program without problem, but when I run it, it always report error.
    my source code is :
    import java.security.*;
    import javax.net.ssl.*;
    System.out.println("Classpath ->"+System.getProperty("java.class.path"));
    SSLSocketFactory factory = (SSLSocketFactory)SSLSocketFactory.getDefault();
    SSLSocket SSLcontrol_connection = (SSLSocket)factory.createSocket(ftp_server, 990);
    SSLcontrol_connection.startHandshake();
    ..........the erroe message is:
    Classpath ->O:\hpovams_dev_sd40\sd\lib\JClark.zip;O:\hpovams_dev_sd40\sd\lib\jcert.jar;O:\hpovams_dev_sd40\sd\lib\jnet.jar;O:\hpovams_dev_sd40\sd\lib\jsse.jar;..........
    java.lang.NoClassDefFoundError
    at javax/net/ssl/SSLSocketFactory.a (DashoA12275)
    at javax/net/ssl/SSLSocketFactory.getDefault (DashoA12275)It is not a classpath problem as I have included the 3 jar files into classpath,.
    I also tried to add
    Security.addProvider(new com.sun.net.ssl.internal.ssl.Provider());before create SSLSocketFactory, then it report that
    java.lang.NoClassDefFoundError
         at com/sun/net/ssl/internal/ssl/Provider.<init> (DashoA12275)My developing GUI is eclipse 3.1, and the OS is winXP.
    Please give me some help, thank you very much.

    oh. I have found the problem. Acturally, the running enviroment is under microsoft j++, so it could only support jdk1.1, but jsse only support from jdk1.2, so that's the problem why it said that no class found.
    Now I only found that oracle has a solution for SSL which support
    jkd1.1(SUN's jsse package only support from jdk1.2). It described the
    method and sample code in Oracle Advanced Security Administrator's
    Guide Release 2 (9.2)
    (http://www.stanford.edu/dept/itss/docs/oracle/9i/network.920/a96573/a...)

  • Help with error  "main" java.lang.NoClassDefFoundError:

    I am pretty new to Java and I just install the JDK1.4.2 03
    I am getting an error when I run the class file TestChart.class with the
    java.exe:
    Exception in thread "main" java.lang.NoClassDefFoundError:
    I have several class files in the directory d:\personal\java-ChartGen
    Chart.class
    ChartColourScheme.class
    ChartPanel.class
    ColorPanel.class
    TestChart.class
    TestIt.class
    All these files are for the program.
    Can some one help me why is this happening?? Is there something I can do
    that I am missing???
    I tried using the -CLASSPATH to direct it to the same directory but still
    with the same error.
    Please help me. Thank you

    I use the command line as follows:
    c:\j2sdk1.4.2_03\bin\java d:\personal\java-ChartGen\TestChart.class
    The full error message is as follows:
    Exception in thread "main" java.lang.NoClassDefFoundError:
    d:\personal\java-ChartGen\TestChart/class
    I thought it may be the CLASSPATH, but all my class files are located in the
    same folder and I used the switch -classpath but the same error comes up.

  • Help on "java.lang.NoClassDefFoundError: oracle/jsp/runtimev2/JspReportUtil"

    Hi all,
    I encounted the following exception on a deployed project to ias 9.0.2:
    500 Internal Server Error
    java.lang.NoClassDefFoundError: oracle/jsp/runtimev2/JspReportUtil     at oracle.jsp.runtimev2.JspServlet.service(JspServlet.java:333)     at javax.servlet.http.HttpServlet.service(HttpServlet.java:336)     at com.evermind[Oracle9iAS (9.0.2.0.0) Containers for J2EE].server.http.ResourceFilterChain.doFilter(ResourceFilterChain.java(Compiled Code))     at oracle.security.jazn.oc4j.JAZNFilter.doFilter(JAZNFilter.java(Compiled Code))     at com.evermind[Oracle9iAS (9.0.2.0.0) Containers for J2EE].server.http.ServletRequestDispatcher.invoke(ServletRequestDispatcher.java(Compiled Code))     at com.evermind[Oracle9iAS (9.0.2.0.0) Containers for J2EE].server.http.ServletRequestDispatcher.include(ServletRequestDispatcher.java:108)     at com.evermind[Oracle9iAS (9.0.2.0.0) Containers for J2EE].server.http.EvermindPageContext.handlePageThrowable(EvermindPageContext.java:596)     at com.evermind[Oracle9iAS (9.0.2.0.0) Containers for J2EE].server.http.EvermindPageContext.handlePageException(EvermindPageContext.java:567)     at data.lookjjview._jspService(_lookjjview.java(Compiled Code))     at com.orionserver[Oracle9iAS (9.0.2.0.0) Containers for J2EE].http.OrionHttpJspPage.service(OrionHttpJspPage.java:56)     at oracle.jsp.runtimev2.JspPageTable.service(JspPageTable.java:302)     at oracle.jsp.runtimev2.JspServlet.internalService(JspServlet.java:407)     at oracle.jsp.runtimev2.JspServlet.service(JspServlet.java:330)     at javax.servlet.http.HttpServlet.service(HttpServlet.java:336)     at com.evermind[Oracle9iAS (9.0.2.0.0) Containers for J2EE].server.http.ResourceFilterChain.doFilter(ResourceFilterChain.java(Compiled Code))     at oracle.security.jazn.oc4j.JAZNFilter.doFilter(JAZNFilter.java(Compiled Code))     at com.evermind[Oracle9iAS (9.0.2.0.0) Containers for J2EE].server.http.ServletRequestDispatcher.invoke(ServletRequestDispatcher.java(Compiled Code))     at com.evermind[Oracle9iAS (9.0.2.0.0) Containers for J2EE].server.http.ServletRequestDispatcher.forwardInternal(ServletRequestDispatcher.java(Compiled Code))     at com.evermind[Oracle9iAS (9.0.2.0.0) Containers for J2EE].server.http.HttpRequestHandler.processRequest(HttpRequestHandler.java(Compiled Code))     at com.evermind[Oracle9iAS (9.0.2.0.0) Containers for J2EE].server.http.AJPRequestHandler.run(AJPRequestHandler.java:151)     at com.evermind[Oracle9iAS (9.0.2.0.0) Containers for J2EE].util.ThreadPoolThread.run(ThreadPoolThread.java(Compiled Code))
    I found there is leak of memory resource on the Oracle RDBMS host while this problem occurs,the database host has only 512Mb RAM.And I once configred the database to worked on Shared Mode,in this case the database has less chance of memory leak,but the above exception occurs more often.So I have to change the database to work back on Dedicate Mode!It's hard to find any tips on my Exception as mentioned above.
    And I want to know the working principle of servlet on iAS.When invoke a servlet,will the servlet be cached on Memory from the first request,or it will be clear up and re-inload until next request?I just wonder if the iAS server will run out of memory,because I noticed there is a memory configure option in "jser.properties" file.And the exception I encoutered seems to occur at a critical point.

    Thanks but that did help since they are talking about
    JDK1.3. I downloaded J2SDK-Beta 3 it says that you
    don't need to set a class path variable. You need to be careful about how you interpret this statement. The rule is, if your system doesn't have a classpath set, you'll get a default of the current directory (.). If your system does have a classpath setting, then the setting will be used.
    Just because you didn't set your classpath doesn't mean someone or some other application didn't. Make sure that your system doesn't have a classpath setting. If it does, you may need to add the current directory (.) to it.

  • [Help]Migrating to OBIEE has java.Lang.NoCLassDefFoundError

    Hi,
    When I try to migrate report to obiee according to guide, there are classic error of java "java.Lang.NoCLassDefFoundError"
    My steps are:
    1) set classpath=C:\OracleBI\oc4j_bi\j2ee\home\applications\xmlpserver\xmlpserver\WEB-INF\lib
    (this is the path can find aolj.jar;xdoparser.jar;collections.jar;versioninfo.jar;xmlparserv2-904.jar)
    2) Download patch p5472959_11i_WINNT.zip from metlink and put j5472959_xdo.zip into above lib
    3) call from command line of windows XP:
    java -verbose -classpath oracle.apps.xdo.rdfparser.DataTemplateGenerator C:\biout\test.xml
    or
    java -verbose -classpath aolj.jar;xdoparser.jar;collections.jar;j5472959_xdo.zip;versioninfo.jar;xmlparserv2-904.jar oracle.apps.xdo.rdfparser.DataTemplateGenerator C:\biout\test.xml
    But... No matther how to change the classpath and java command, there always has error:
    Exception in thread main java.Lang.NoCLassDefFoundError C:\biout\test/xml
    (PS: is not error of Exception in thread main java.Lang.NoCLassDefFoundError oracle.apps.xdo.rdfparser.DataTemplateGenerator, so I think system can find oracle.apps.xdo.rdfparser.DataTemplateGenerator, but it doesn't recongize C:\biout\test.xml )
    Can any person help me? Thanks a lot.

    I wouldn't recommend setting the CLASSPATH variable... it's OK for now, but it'll become problematic in the long term... so IMHO you may as well form good habits upfront.
    To compile:
    C:\javacode>javac -d "." Example.java
    To execute:
    C:\javacode>java -classpath "." Example
    Or as of java 1.5 you can shorten that to:
    C:\javacode>java -cp "." Example
    java -version
    tells you which version of java you're running.
    Cheers, Keith.

  • JDBC help needed ; java.lang.NoClassDefFoundError:test1

    hi, everyone, i had a problem when i run my own app to connect javadb in embedded mode
    i ve added the ~/javadb/lib/derby.jar to CLASSPATH
    and ~/javadb/lib/derby.jar:~/javadb/lib/derbytools.jar to DERBY_HOME
    but there is a problem said my own application class cannot be found.
    here is my code:
    import java.sql.*;
    class test1
      public static void main (String args [])
           throws SQLException
           try {
            Class.forName("org.apache.derby.jdbc.EmbeddedDriver");
        } catch (Exception e) {
            System.out.println("ERROR: failed to load javadb JDBC driver.");
            e.printStackTrace();
            return;
          Connection conn = DriverManager.getConnection("jdbc:derby:testdb");
      try{
         Statement stmt1 = conn.createStatement();
            ResultSet rset1 = stmt1.executeQuery( "SELECT * FROM PART" );
         long counter1 = 0;
            double price1;
         while ( rset1.next() )
             price1 = rset1.getDouble(8);
             if (price1 == 1306.4)
              counter1++;
         System.out.println( counter1 );
         stmt1.executeQuery("SHUTDOWN");
         conn.close();
       catch (SQLException e )
         String errmsg = e.getMessage();
         System.out.println( errmsg );
    }and i ve followed one Derby JDBC tutorial on the internet,
    * AutoLoadJdbcDriver.java
    * Copyright (c) 2007 by Dr. Herong Yang. All rights reserved.
    import java.sql.*;
    import java.util.*;
    public class AutoLoadJdbcDriver {
      public static void main(String [] args) {
        Connection con = null;
        try {
          listDrivers();
    // Find the driver for a given URL
          Driver driverClass = (Driver) DriverManager.getDriver(
            "jdbc:derby://somehost/somedb");
          System.out.println("\nDriver for jdbc:derby://somehost/somedb");
          System.out.println("   "+driverClass.getClass().getName());
          listDrivers();
        } catch (Exception e) {
          System.err.println("Exception: "+e.getMessage());
      private static void listDrivers() {
        Enumeration driverList = DriverManager.getDrivers();
        System.out.println("\nList of drivers:");
        while (driverList.hasMoreElements()) {
          Driver driverClass = (Driver) driverList.nextElement();
          System.out.println("   "+driverClass.getClass().getName());
    The output below confirms that the DriverManager class is able to load any JDBC driver classes as long as their JAR files are included in the classpath.
    C:\>javac AutoLoadJdbcDriver.java
    C:\>java -cp .;\local\javadb\lib\derbyclient.jar AutoLoadJdbcDriver
    List of drivers:
    sun.jdbc.odbc.JdbcOdbcDriver
    org.apache.derby.jdbc.ClientDriver
    Driver for jdbc:derby://somehost/somedb
    org.apache.derby.jdbc.ClientDriver
    List of drivers:
    sun.jdbc.odbc.JdbcOdbcDriver
    org.apache.derby.jdbc.ClientDriver
    but on my machine , it keep telling me the massage
    Exception in thread "main" java.lang.NoClassDefFoundError: SimpleApp
    Exception in thread "main" java.lang.NoClassDefFoundError: test1
    Exception in thread "main" java.lang.NoClassDefFoundError: AutoLoadJdbcDriver
    the ij works well
    and the other java app(without jdbc) works well.
    anybody can help me to solve this problem?
    Edited by: Xiao on Jan 18, 2008 6:19 PM

    but on my machine , it keep telling me the massage
    Exception in thread "main" java.lang.NoClassDefFoundError: SimpleApp
    Exception in thread "main" java.lang.NoClassDefFoundError: test1
    Exception in thread "main" java.lang.NoClassDefFoundError: AutoLoadJdbcDriverI assume you get these messages when you try and run the three programs mentioned (SimpleApp, test1 and AutoLoadJdbcDriver).
    What commands do you use to do this? What does the command line report the CLASSPATH to be (using the echo command)?
    The simplest cause would be that you have the derby jar mentioned as part of CLASSPATH, but not the current directory.

  • Help me. - java.lang.NoClassDefFoundError

    Hello.
    Sombody help me.
    My TesterBean call to TraderBean.
    But TesterBean not found traderClient.jar.
    The traderClient.jar include TraderHome and Trader class.
    Is traderClient.jar set to classpath of WLS6.1?
    For example, Writing in a startSever.cmd file?
    startSever.cmd ----------------------------
    set CLASSPATH=.;.\lib\weblogic_sp.jar;. . . ;traderClient.jar
    Does traderClient.jar must setted at startServer.cmd?
    But I don't want to this setting.
    Thanks.
    Min
    My Program source.
    My TesterBean's ejb_MANIFEST.MF content is ............
    Manifest-Version: 1.0
    Class-Path: traderClient.jar
    public class TesterBean implements SessionBean {
    public void test() throws NamingException, Exception
    try {
    TraderHome home = (TraderHome)ctx.lookup("ejb20-statelessSession-TraderHome");
    Exception ..............
    java.rmi.RemoteException: EJB Exception: ; nested exception is:
    java.lang.NoClassDefFoundError: examples/ejb20/basic/statelessSession/TraderHome
    TesterBean's Build.xml contents..
    <target name="jar_ejb" depends="compile_ejb">
    <jar jarfile="${dist}/std_ejb20_basic_tester.jar" basedir="${build}" manifest="ejb_MANIFEST.MF">
    TraderBean's ejb-jar.xml contents ....
    <ejb-client-jar>traderClient.jar</ejb-client-jar>
    [att1.html]

    im having similar problems. i suspect it has something to do with the classpath...but as of yet im still stuck. i get this error when i attempt to start the tomcat that coems with jwsdp1.1

  • Help for java.lang.NoClassDefFoundError:

    hi all, i wrote a jws shows the following.
    import java.lang.*;
    import java.util.*;
    * * @author bow5003
    public class CalculatorWithDLL {
    private native float add(float num1, float num2);
    private native float sub(float num1, float num2);
    private native float mult(float num1, float num2);
    private native float divid(float num1, float num2);
    private native float square(float num1);
    private native float tripple(float num1);
    //private float result;
    /** Creates a new instance of CalculatorWithDLL */
    public static float getAdd(float num1, float num2) {
    CalculatorWithDLL calculator = new CalculatorWithDLL();
    float result = calculator.add(num1, num2);
    return result;
    public static float getSub(float num1, float num2){
    CalculatorWithDLL calculator = new CalculatorWithDLL();
    float result = calculator.sub(num1, num2);
    return result;
    public static float getMult(float num1, float num2) {
    CalculatorWithDLL calculator = new CalculatorWithDLL();
    float result = calculator.mult(num1, num2);
    return result;
    public static float getDivid(float num1, float num2) {
    CalculatorWithDLL calculator = new CalculatorWithDLL();
    float result = calculator.divid(num1, num2);
    return result;
    public static float getSquare(float num1) {
    CalculatorWithDLL calculator = new CalculatorWithDLL();
    float result = calculator.square(num1);
    return result;
    public static float getTriple(float num1) {
    CalculatorWithDLL calculator = new CalculatorWithDLL();
    float result = calculator.tripple(num1);
    return result;
    static {
    System.loadLibrary("Calculator");
    and when i try to access throw the web browser http://localhost:8080/axis/JWS_Files/CalculatorWithDLL.jws?wsdl it gives the error:
    java.lang.NoClassDefFoundError: Could not initialize class CalculatorWithDLL
    at java.lang.Class.forName0(Native Method)
    at java.lang.Class.forName(Class.java:247)
    at org.apache.axis.utils.ClassUtils$2.run(ClassUtils.java:168)
    at java.security.AccessController.doPrivileged(NativeMethod)
    at org.apache.axis.utils.ClassUtils.loadClass(ClassUtils.java:160)
    at org.apache.axis.utils.ClassUtils.forName(ClassUtils.java:142)
    at org.apache.axis.utils.cache.ClassCache.lookup(ClassCache.java:85)
    at org.apache.axis.providers.java.JavaProvider.getServiceClass(JavaProvider.java:428)
    at org.apache.axis.providers.java.JavaProvider.initServiceDesc(JavaProvider.java:461)
    at org.apache.axis.handlers.soap.SOAPService.getInitializedServiceDesc(SOAPService.java:286)
    at org.apache.axis.handlers.JWSHandler.setupService(JWSHandler.java:273)
    at org.apache.axis.handlers.JWSHandler.generateWSDL(JWSHandler.java:294)
    at org.apache.axis.strategies.WSDLGenStrategy.visit(WSDLGenStrategy.java:33)
    at org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:118)
    at org.apache.axis.SimpleChain.generateWSDL(SimpleChain.java:104)
    at org.apache.axis.server.AxisServer.generateWSDL(AxisServer.java:454)
    at org.apache.axis.transport.http.QSWSDLHandler.invoke(QSWSDLHandler.java:68)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(NativeMethod)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:597)
    at org.apache.axis.transport.http.AxisServlet.processQuery(AxisServlet.java:1226)
    at org.apache.axis.transport.http.AxisServlet.doGet(AxisServlet.java:249)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:690)
    at org.apache.axis.transport.http.AxisServletBase.service(AxisServletBase.java:327)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
    at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:230)
    at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
    at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
    at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:104)
    at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
    at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:261)
    at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)
    at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:581)
    at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
    at java.lang.Thread.run(Thread.java:619)
    anyone can help me?
    Message was edited by:
    BCW0928
    Message was edited by:
    BCW0928

    Where is the dll ?
    you need to include it in a jar, and ref that jar with
    <nativelib href=<url to the jar>/>
    and request all-permissions in you jnlp file (and sign both jars)
    /Andy

  • Java.lang.NoClassDefFoundError: com/sap/tc/webdynpro/adsproxy/types/p1/RpDa

    Hi All,
    I have created and deployed an EJB application in CE7.1,I am using this jars "_webdynpro_pdfobject.jar",for read the xml data in pdf ,For that time i am getting following errors",
    Exception in thread "main" java.lang.NoClassDefFoundError: com/sap/tc/webdynpro/adsproxy/types/p1/RpDataat com.sap.tc.webdynpro.pdfobject.api.WDPDFObjectFactory.getPDFObject(WDPDFObjectFactory.java:43)
    Plz anyone suggest
    Regards,
    Vinoth Raja.V

    Well, first of all, you should not use a Web Dynpro API in an EJB app. Web Dynpro is a UI technology, EJB implements the business logic.
    Furthermore, the PDFObject API has been deprecated. For more information and guidance, please refer to its [javadoc|http://help.sap.com/javadocs/nwce/current/wdr/com/sap/tc/webdynpro/pdfobject/api/package-summary.html].
    HTH!
    \-- Vladimir
    P.S.: Please read the [Rules|https://wiki.sdn.sap.com/wiki/display/HOME/RulesofEngagement], in particular regarding cross-posting.

Maybe you are looking for