Servlet cannot find classes when in a EAR

          Hi
          I have a EAR that contains a EJB module and a web application module.
          The Web application module contains two servlets to be deployed. One is Action
          Servlet (struts.jar) and the other is our home-made. I am able to deploy the
          WAR and JAR separately, but when these are packaged in an EAR I get the following
          errors
          <03-Oct-2003 11:14:58 o'clock BST> <Error> <HTTP> <BEA-101254> <[ServletContext(id=6832671,name=payments-web,context-path=/payments-web)]:
          Servlet class org.apache.struts.action.ActionServlet for servlet action could
          not be handled by the classloader with classpath C:\bea2\user_projects\domains\paymentsdomain\myserver\upload\payments.ear\payments-web.war;C:\bea2\user_projects\domains\paymentsdomain\myserver\upload\payments.ear\payments-web.war\WEB-INF\classes;C:\bea2\user_projects\domains\paymentsdomain\.\myserver\.wlnotdelete\extract\myserver_payments_payments-web\jarfiles\WEB-INF\lib\struts30440.jar.
          java.lang.ExceptionInInitializerError.>
          <03-Oct-2003 11:14:58 o'clock BST> <Error> <HTTP> <BEA-101216> <Servlet: "action"
          failed to preload on startup in Web application: "payments-web".
          javax.servlet.ServletException: [HTTP:101254][ServletContext(id=6832671,name=payments-web,context-path=/payments-web)]:
          Servlet class org.apache.struts.action.ActionServlet for servlet action could
          not be handled by the classloader with classpath C:\bea2\user_projects\domains\paymentsdomain\myserver\upload\payments.ear\payments-web.war;C:\bea2\user_projects\domains\paymentsdomain\myserver\upload\payments.ear\payments-web.war\WEB-INF\classes;C:\bea2\user_projects\domains\paymentsdomain\.\myserver\.wlnotdelete\extract\myserver_payments_payments-web\jarfiles\WEB-INF\lib\struts30440.jar.
          java.lang.ExceptionInInitializerError.
          at weblogic.servlet.internal.ServletStubImpl.prepareServlet(ServletStubImpl.java:822)
          at weblogic.servlet.internal.WebAppServletContext.preloadServlet(WebAppServletContext.java:3236)
          at weblogic.servlet.internal.WebAppServletContext.preloadServlets(WebAppServletContext.java:3181)
          at weblogic.servlet.internal.WebAppServletContext.preloadResources(WebAppServletContext.java:3154)
          at weblogic.servlet.internal.WebAppServletContext.setStarted(WebAppServletContext.java:5637)
          at weblogic.servlet.internal.WebAppModule.start(WebAppModule.java:866)
          at weblogic.j2ee.J2EEApplicationContainer.start(J2EEApplicationContainer.java:2017)
          at weblogic.j2ee.J2EEApplicationContainer.activate(J2EEApplicationContainer.java:2058)
          at weblogic.management.deploy.slave.SlaveDeployer$ComponentActivateTask.activateContainer(SlaveDeployer.java:2624)
          at weblogic.management.deploy.slave.SlaveDeployer$ActivateTask.doCommit(SlaveDeployer.java:2547)
          at weblogic.management.deploy.slave.SlaveDeployer$Task.commit(SlaveDeployer.java:2349)
          at weblogic.management.deploy.slave.SlaveDeployer$Task.checkAutoCommit(SlaveDeployer.java:2431)
          at weblogic.management.deploy.slave.SlaveDeployer$Task.prepare(SlaveDeployer.java:2343)
          at weblogic.management.deploy.slave.SlaveDeployer$ActivateTask.prepare(SlaveDeployer.java:2511)
          at weblogic.management.deploy.slave.SlaveDeployer.processPrepareTask(SlaveDeployer.java:833)
          at weblogic.management.deploy.slave.SlaveDeployer.prepareDelta(SlaveDeployer.java:542)
          at weblogic.management.deploy.slave.SlaveDeployer.prepareUpdate(SlaveDeployer.java:500)
          at weblogic.drs.internal.SlaveCallbackHandler$1.execute(SlaveCallbackHandler.java:25)
          at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:197)
          at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:170)
          >
          <03-Oct-2003 11:14:58 o'clock BST> <Warning> <Deployer> <BEA-149004> <Failures
          were detected while initiating Deploy task for application payments.>
          <03-Oct-2003 11:14:58 o'clock BST> <Error> <Deployer> <BEA-149201> <Failed to
          complete the deployment task with ID 1 for the application payments.
          weblogic.management.DeploymentException:
          Exception:weblogic.management.ApplicationException: start() failed.
          Module: payments-web Error: java.lang.ExceptionInInitializerError
          My observations are
          1. The servlet has been located.
          2. Please note the <Warn> message that the ActionServlet class could not be handled
          by the classloader. What does this mean ???
          3 I also tried putting these jars in APP-INF/lib but got the same errors
          I am using WLS 8.1 SP1 on XP professional
          Thanks
          Jasmeet
          

          Just to add on to that ...
          If I put all my required/referemced application classes and dependent classes
          in System CLASSPATH, the whole deploys and runs quite nicely.
          Is that allowed ?? Would it not be better to have some application level classloading
          rather than going for the system classpath
          thanks
          jasmeet
          "jasmeet" <[email protected]> wrote:
          >
          >Hi
          >
          >I have a EAR that contains a EJB module and a web application module.
          >The Web application module contains two servlets to be deployed. One
          >is Action
          >Servlet (struts.jar) and the other is our home-made. I am able to deploy
          >the
          >WAR and JAR separately, but when these are packaged in an EAR I get the
          >following
          >errors
          >
          ><03-Oct-2003 11:14:58 o'clock BST> <Error> <HTTP> <BEA-101254> <[ServletContext(id=6832671,name=payments-web,context-path=/payments-web)]:
          >Servlet class org.apache.struts.action.ActionServlet for servlet action
          >could
          >not be handled by the classloader with classpath C:\bea2\user_projects\domains\paymentsdomain\myserver\upload\payments.ear\payments-web.war;C:\bea2\user_projects\domains\paymentsdomain\myserver\upload\payments.ear\payments-web.war\WEB-INF\classes;C:\bea2\user_projects\domains\paymentsdomain\.\myserver\.wlnotdelete\extract\myserver_payments_payments-web\jarfiles\WEB-INF\lib\struts30440.jar.
          >java.lang.ExceptionInInitializerError.>
          ><03-Oct-2003 11:14:58 o'clock BST> <Error> <HTTP> <BEA-101216> <Servlet:
          >"action"
          >failed to preload on startup in Web application: "payments-web".
          >javax.servlet.ServletException: [HTTP:101254][ServletContext(id=6832671,name=payments-web,context-path=/payments-web)]:
          >Servlet class org.apache.struts.action.ActionServlet for servlet action
          >could
          >not be handled by the classloader with classpath C:\bea2\user_projects\domains\paymentsdomain\myserver\upload\payments.ear\payments-web.war;C:\bea2\user_projects\domains\paymentsdomain\myserver\upload\payments.ear\payments-web.war\WEB-INF\classes;C:\bea2\user_projects\domains\paymentsdomain\.\myserver\.wlnotdelete\extract\myserver_payments_payments-web\jarfiles\WEB-INF\lib\struts30440.jar.
          >java.lang.ExceptionInInitializerError.
          > at weblogic.servlet.internal.ServletStubImpl.prepareServlet(ServletStubImpl.java:822)
          > at weblogic.servlet.internal.WebAppServletContext.preloadServlet(WebAppServletContext.java:3236)
          > at weblogic.servlet.internal.WebAppServletContext.preloadServlets(WebAppServletContext.java:3181)
          > at weblogic.servlet.internal.WebAppServletContext.preloadResources(WebAppServletContext.java:3154)
          > at weblogic.servlet.internal.WebAppServletContext.setStarted(WebAppServletContext.java:5637)
          > at weblogic.servlet.internal.WebAppModule.start(WebAppModule.java:866)
          > at weblogic.j2ee.J2EEApplicationContainer.start(J2EEApplicationContainer.java:2017)
          > at weblogic.j2ee.J2EEApplicationContainer.activate(J2EEApplicationContainer.java:2058)
          > at weblogic.management.deploy.slave.SlaveDeployer$ComponentActivateTask.activateContainer(SlaveDeployer.java:2624)
          > at weblogic.management.deploy.slave.SlaveDeployer$ActivateTask.doCommit(SlaveDeployer.java:2547)
          > at weblogic.management.deploy.slave.SlaveDeployer$Task.commit(SlaveDeployer.java:2349)
          > at weblogic.management.deploy.slave.SlaveDeployer$Task.checkAutoCommit(SlaveDeployer.java:2431)
          > at weblogic.management.deploy.slave.SlaveDeployer$Task.prepare(SlaveDeployer.java:2343)
          > at weblogic.management.deploy.slave.SlaveDeployer$ActivateTask.prepare(SlaveDeployer.java:2511)
          > at weblogic.management.deploy.slave.SlaveDeployer.processPrepareTask(SlaveDeployer.java:833)
          > at weblogic.management.deploy.slave.SlaveDeployer.prepareDelta(SlaveDeployer.java:542)
          > at weblogic.management.deploy.slave.SlaveDeployer.prepareUpdate(SlaveDeployer.java:500)
          > at weblogic.drs.internal.SlaveCallbackHandler$1.execute(SlaveCallbackHandler.java:25)
          > at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:197)
          > at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:170)
          >>
          ><03-Oct-2003 11:14:58 o'clock BST> <Warning> <Deployer> <BEA-149004>
          ><Failures
          >were detected while initiating Deploy task for application payments.>
          ><03-Oct-2003 11:14:58 o'clock BST> <Error> <Deployer> <BEA-149201> <Failed
          >to
          >complete the deployment task with ID 1 for the application payments.
          >weblogic.management.DeploymentException:
          >Exception:weblogic.management.ApplicationException: start() failed.
          > Module: payments-web Error: java.lang.ExceptionInInitializerError
          >
          >
          >
          >My observations are
          >1. The servlet has been located.
          >2. Please note the <Warn> message that the ActionServlet class could
          >not be handled
          >by the classloader. What does this mean ???
          >3 I also tried putting these jars in APP-INF/lib but got the same errors
          >
          >
          >I am using WLS 8.1 SP1 on XP professional
          >
          >
          >Thanks
          >Jasmeet
          

Similar Messages

  • Cannot find class: Exception??

    Hi
    The compiler claims it cannot find class FileNotFoundException or any other exception in my Main. Any packages I import has no problem. My structure:
    java \ myMain \ Main.java
    java \ com \ myName \ packages //no, the space is just there as visual help:)
    Use javac -classpath java\ @compile.file
    ...where compile.file is a txt file giving the paths and filenames to all files I include.
    This is first time I use the -classpath parameter, but I believed java.lang always was included. What Am I doing wrong.
    regards
    JT

    You should review the tool documentation for the javac command and its use of classpath.
    Your problem appears to be due to the way you defined classpath, "-classpath java\". While you don't provide enough information to conclusively say what it should be, I'm guessing it should also include java\myMain\ - assuming that you're issuing the javac command from the parent of the \java\ directory, as your command example indicates.
    Here is a clip about its use of the classpath.
    "When compiling a source file, the compiler often needs information about a type whose definition did not appear in the source files given on the command line. The compiler needs type information for every class or interface used, extended, or implemented in the source file. This includes classes and interfaces not explicitly mentioned in the source file but which provide information through inheritance.
    For example, when you subclass java.applet.Applet, you are also using Applet's ancestor classes: java.awt.Panel, java.awt.Container, java.awt.Component, and java.lang.Object.
    When the compiler needs type information, it looks for a source file or class file which defines the type. The compiler searches for class files first in the bootstrap and extension classes, then in the user class path (which by default is the current directory). The user class path is defined by setting the CLASSPATH environment variable or by using the -classpath command line option. (For details, see Setting the Class Path).
    If you set the -sourcepath option, the compiler searches the indicated path for source files; otherwise the compiler searches the user class path for both class files and source files."

  • Preverification error: Cannot find class com/sun/perseus/model/Viewport

    Hi all,
    I have a (previously) working Midlet to which I have added one line as follows:
    SVGImage image = (SVGImage)SVGImage.createEmptyImage(null);
    - and imported the necessary from javax.microedition.m2g. (I am using the library that comes with the WTK, jsr226.jar).
    This builds, jars, obfuscates fine. But when I try to preverify (using Antenna's wtkpreverify) on the jar, it gives up in disgust very swiftly as follows:
    [wtkpreverify] Error preverifying class javax.microedition.m2g.ScalableGraphics
    [wtkpreverify] VERIFIER ERROR javax/microedition/m2g/ScalableGraphics.render(IILjavax/microedition/m2g/ScalableImage;)V:
    [wtkpreverify] Cannot find class com/sun/perseus/model/Viewport
    I'm using the WTK2.5.1ea and antenna 0.9.14, CLDC1.1, MIDP2.0...
    Many thanks for any ideas.

    Problem resolved simply by replacing jsr226.jar (as distributed with WTK2.5.1ea) with m2g.jar (as distributed with J2MEPolish).

  • Cannot find class JPanel

    Hi,
    Im trying to use swing for almost the first time.
    I changed my system to Linux and installed J2sdk 1.4.
    When I write a class
    e.g.
    import javax.swing.*;
    import java.awt.*;
    etc...
    class Test extends JPanel {
    I receive an error message "Cannot find class "JPanel""
    Can anyone help ? Maybe I didnt install the right thing ?
    Thanks
    Ulrike

    you sure reinstall and overwrite your current sdk. Do you have the runtime environment installed too -- should come with the sdk

  • Cannot find class java/lang/Thread

    I'm getting this error trying to compile a program that I'm writing in java. Its a very simple program just to get me back to basics. Any ideas as to how I can fix this problem??

    Extracted from Sun's website,
    * Error Message: "Exception in thread NULL" or
    "Unable to initialize threads: cannot find class java/lang/Thread"
    If you are getting one of these fatal error messages when running java,
    javac, or appetviewer, you should check your CLASSPATH environment variable.
    It may list "c:\java" or the "classes" directory from an older release. You can either unset the CLASSPATH variable, or set it to
    include only the latest version of the Java platform class library. For example:
    C:\> set CLASSPATH=.;C:\jdk1.1.8\lib\classes.zip
    This will make sure that you are using the correct classes for this release.
    -- Sudha

  • Cannot find lib when packaging for iOS

    You can see the same question on StackOverflow here:
    http://stackoverflow.com/questions/11547515/cannot-find-lib-when-packaging-for-ios
    Hi,
    I am developping an Air Native Extension (ANE) in order to be able to use the burstly(1) ads on mobile devices.
    As for my setup, I am using the FlashDevelop 4.0.4(2) and Adobe Air 3.3 (3). I'm using Flex 4.6.0 SDK. The project is setup on Windows7.
    In order to work on iOS devices, Burstly requires a number of frameworks and librares (4)
    I managed to write and compile the .a library for iOS. I also have the interface (actionscript code) that will be shared for Android and iOS compiled into a swc and a librairy.swf. All of this is successfully packaged into a .ane which is included in my project.
    When compiling a .a library on MacOS, all the framework and library used don't seems to be packaged in the ".a". This is why I had to use Air 3.3, for the -platformsdk option(5).
    Since I work on Windows, I followed the instruction in this post to get the iOS SDK (6).
    Following (4) and (5), I made a platformConfig.xml file like this, which is packaged in the .ane
        <platform xmlns="http://ns.adobe.com/air/extension/3.1">
            <sdkVersion>4.2</sdkVersion>
            <linkerOptions>
                <!-- to use the AssetsLibrary framework -->
                <option>-framework AssetsLibrary</option>
                <option>-framework AudioToolbox</option>
                <option>-framework AddressBook</option>
                <option>-framework AVFoundation</option>
                <option>-framework CFNetwork</option>
                <option>-framework CoreLocation</option>
                <option>-framework MapKit</option>
                <option>-framework MediaPlayer</option>
                <option>-framework MessageUI</option>
                <option>-framework OpenAL</option>
                <option>-framework OpenGLES</option>
                <option>-framework QuartzCore</option>
                <option>-framework StoreKit</option>
                <option>-framework SystemConfiguration</option>
                <option>-framework Foundation</option>
                <option>-framework CoreGraphics</option>
                <option>-libsqlite3</option>
                <option>-libxml2</option>
                <option>-libz</option>
            </linkerOptions>
        </platform>
    and this is the line to compile the actuale .ane
        call "%FLEX_SDK%\bin\adt" -package -target ane ../release/burstlyadsextension.ane extension.xml -swc burstlyAds.swc -platform iPhone-ARM library.swf libBurstlyAds.a -platformoptions platformConfig.xml
    Problem arises when I try to package the iOS app with ADT:
        call adt -package -target %TYPE%%TARGET% %OPTIONS% %SIGNING_OPTIONS% "%OUTPUT%" "%APP_XML%" %FILE_OR_DIR% -extdir lib/external/ -platformsdk ../Libraries/iPhoneOS5.0.sdk/
    this happens:
    "ld: library not found for -libsqlite3
    Compilation failed while executing : ld64"
    frameworks seems to be added fine, but the dylib are not. I tried to add the line:
        <option>-L usr/lib/</option>
    before including the lib, but I got this error instead:
    "ld: warning: directory not found for option '-Lusr/lib/'
    ld: library not found for -libsqlite3
    Compilation failed while executing : ld64"
    I tried to use the full path, other relative path, but no matter what path I put in the option, I always get a "warning: directory not found for option". Even "<option>-L ../</option>" give me this warning. The only thing that seems to work is "<option>-L /../</option>", but my .dylib obviousle are not there.
    So my questions are: What did I do wrong? Any idead what else I could try? Even an explanation as to why it is not working would be helpful!
    Links:
    #1: http://support.burstly.com/
    #2: http://www.flashdevelop.org/
    #3: http://get.adobe.com/fr/air/        //Sorry, my OS is in french
    #4: http://support.burstly.com/kb/ios/required-compiler-flags-frameworks
    #5: http://blogs.adobe.com/rajorshi/2011/11/16/ios5-support-for-airusing-external-sdks-to-pack age-apps/
    #6: http://blogs.adobe.com/airodynamics/2012/05/18/using-platformsdk-for-ios-on-windows/

    Thanks a lot, that took care of the
    "ld: library not found for -libsqlite3
    Compilation failed while executing : ld64"
    But now, I'm stuck with this error instead:
    ld: warning: -ios_version_min not specificed, assuming 4.0
    Undefined symbols for architecture armv7:
      "_ADBannerContentSizeIdentifier480x32", referenced from:
          +[Burstly_iad_Adaptor initializeContentSizeIdentifiers] in libcom.bhvr.burstlyads.a(Burstly_iad_Adaptor.o)
          -[Burstly_iad_Adaptor supportedSizes] in libcom.bhvr.burstlyads.a(Burstly_iad_Adaptor.o)
      "_OBJC_CLASS_$_ADBannerView", referenced from:
          objc-class-ref in libcom.bhvr.burstlyads.a(Burstly_iad_Adaptor.o)
      "_OBJC_CLASS_$_EKEventStore", referenced from:
          objc-class-ref in libcom.bhvr.burstlyads.a(BurstlyORMMAView.o)
      "_OBJC_CLASS_$_FlurryAnalytics", referenced from:
          objc-class-ref in libcom.bhvr.burstlyads.a(Burstly_flurry_Adaptor.o)
      "_OBJC_CLASS_$_CMMotionManager", referenced from:
          objc-class-ref in libcom.bhvr.burstlyads.a(BurstlyORMMAJavascriptBridge.o)
      "_ADBannerContentSizeIdentifier320x50", referenced from:
          +[Burstly_iad_Adaptor initializeContentSizeIdentifiers] in libcom.bhvr.burstlyads.a(Burstly_iad_Adaptor.o)
          -[Burstly_iad_Adaptor supportedSizes] in libcom.bhvr.burstlyads.a(Burstly_iad_Adaptor.o)
          -[Burstly_iad_Adaptor makeSizesSetWithArray:] in libcom.bhvr.burstlyads.a(Burstly_iad_Adaptor.o)
      "_MedialetsShouldLogDebug", referenced from:
          -[MedialetsAdServer sendAppPixelWithURL:] in libcom.bhvr.burstlyads.a(MedialetsAdServer.o)
          -[MedialetsAdServer adFitsSlot:adID:] in libcom.bhvr.burstlyads.a(MedialetsAdServer.o)
          -[MedialetsAdServer nextAdFromList:forTargetKey:keywords:andBlockKeywords:] in libcom.bhvr.burstlyads.a(MedialetsAdServer.o)
          -[MedialetsAdServer isAdValidForSlot:forTargetKey:keywords:andBlockKeywords:] in libcom.bhvr.burstlyads.a(MedialetsAdServer.o)
          -[MedialetsAdServer nextAdForAdView:] in libcom.bhvr.burstlyads.a(MedialetsAdServer.o)
          -[MedialetsAdServer startCacheLoad] in libcom.bhvr.burstlyads.a(MedialetsAdServer.o)
          -[MedialetsAdServer processReceivedData:] in libcom.bhvr.burstlyads.a(MedialetsAdServer.o)
      "_OBJC_CLASS_$_EKEvent", referenced from:
          objc-class-ref in libcom.bhvr.burstlyads.a(BurstlyORMMAView.o)
      "_ADBannerContentSizeIdentifierPortrait", referenced from:
          +[Burstly_iad_Adaptor initializeContentSizeIdentifiers] in libcom.bhvr.burstlyads.a(Burstly_iad_Adaptor.o)
      "_OBJC_CLASS_$_CTTelephonyNetworkInfo", referenced from:
          objc-class-ref in libcom.bhvr.burstlyads.a(BurstlyUtils.o)
      "_ADBannerContentSizeIdentifierLandscape", referenced from:
          +[Burstly_iad_Adaptor initializeContentSizeIdentifiers] in libcom.bhvr.burstlyads.a(Burstly_iad_Adaptor.o)
      "_MedialetsShouldLogInternal", referenced from:
          -[MedialetsAdServer init] in libcom.bhvr.burstlyads.a(MedialetsAdServer.o)
          -[MedialetsAdServer qualifiedAdsFromList:forAdView:] in libcom.bhvr.burstlyads.a(MedialetsAdServer.o)
          -[MedialetsAdServer qualifiedAd:foradSlotKey:] in libcom.bhvr.burstlyads.a(MedialetsAdServer.o)
          -[MedialetsAdServer nextAdFromList:forTargetKey:keywords:andBlockKeywords:] in libcom.bhvr.burstlyads.a(MedialetsAdServer.o)
          -[MedialetsAdServer nextAdForAdView:] in libcom.bhvr.burstlyads.a(MedialetsAdServer.o)
          -[MedialetsAdServer attemptCacheLoad] in libcom.bhvr.burstlyads.a(MedialetsAdServer.o)
          -[MedialetsAdServer startCacheLoad] in libcom.bhvr.burstlyads.a(MedialetsAdServer.o)
      "_OBJC_CLASS_$_FlurryAppCircle", referenced from:
          objc-class-ref in libcom.bhvr.burstlyads.a(Burstly_flurry_Adaptor.o)
      "_OBJC_CLASS_$_ADInterstitialAd", referenced from:
          objc-class-ref in libcom.bhvr.burstlyads.a(Burstly_iad_Adaptor.o)
    ld: symbol(s) not found for architecture armv7
    Compilation failed while executing : ld64
    Which is the same error as when I did not include any library at all.
    Any other insight?

  • Cannot find class "Hello"

    Hi,
    I'm developing a application for a windows ce v.2.11, and I've installed in my PDA (MIPS) Personal Java. The samples of Personal Java run perfectly. I've create a simple new class (Hello.class) with Sun One Studio, then I copy this file (Hello.class) in my pda, and when I run the application I saw this messages: "Cannot find class Hello".
    Anybody can explain me step by step the correct way to create a new class or a new jre to run in my PDA?
    Another question: Where are installed the classes as AWT?
    Thanks

    Please see my reply to your latest post.

  • Error:Cannot find class

    Hi
    I compile my application correctly, but when I copy this application in my PDA, and run this application (Hello.class) with Personal Java I saw a this message: Cannot find class Hello.class.
    I don't compile javacheck before copy in my PDA the application.
    Please help me

    Hi,
    are you sure that your classpath is set correct?
    For checking this you'll need a registry editor and check the command that is entered for the .class file extensions.
    Have a nice day,
    FReAK

  • Java teststand - Error 1500 Cannot find class

    Hi everyone,
    I am using TestStand 2010 and Java 1.7.
    I try to add a java class in the Computer example folder, and call the method.
    The java class is simply like below, because I just want to try calling my own java class.
    I have set the Class Path in Start JVM to the directory where the Computer example (which is also the directory where I put my java class) are located.
    TestStand can call the Computer's methods, but not mine (got error Error 1500 Cannot find class). I put my my java method calling among the defaults Computer example calls.
    Furthermore I have read similiar threads but still I cannot solve the error.
    Where is the part I miss, actually? Please share some insights.
    Note: I even try to leave the Class Path empty, but TestStand still can call the Computer's methods. Why?
    public class TestJava {
    public static void main(String[] args) {
    public String returnString(boolean a){
    return "success";
    Solved!
    Go to Solution.

    In order to load a class that is inside a package you have to use the package notation (or modify the example in order to use it). The path to the class is passed directly to the JVM in order to load the class, but really what is needed is the package from the class path including the full path to the class. 
    That means you have to do the following:
    1. Set the class path to the base directory where you built all your classes, if you have the following structure:
    MyFile.java
    builds
    MyPackage
    MyFile.class
    You have to set the classpath to the builds directory
    2. When you configure your steps, you have to set the path to the class in your Java steps to MyPackage/MyFile.class (note separator is a slash, not the usual Windows backslash, so the browse button doesn't quite help with that). 
     Another important thing is that when you set the classpath you are deleting the normal class path in Java, if you are using Java classes from the default libraries you might have to add <jre directory>\lib\rt.jar

  • HT1473 I am trying to upload my itunes music from my ipod to my computer.  My current Itunes library is listing the songs, but cannot find them when I try to put them on to my iphone.

    I am trying to upload my itunes music from my ipod to my itunes on my computer.  My itunes music lists all of the music, but cannot find it when I try to load it to my phone.
    The songs are on my ipod, but not on my phone and I don't know how to get them from one device to the other.

    In your case, it would be better to have transferred the library to an external drive from the PC. Then, connect it to the iMac and put the library onto the Music folder.
    You used Migration Assistant, and it creates a new user with the transferred data.
    Open  > Log Out, and log in the new user. Then, open a Finder window, choose Music in the sidebar and you will see the iTunes library. Now, you have to move the iTunes library to /Users/Shared (select Go menu -in the menu bar- > Go to Folder, type that and copy the iTunes library to it). Finally, log in the other user, go to the same folder and move the library to the Music folder.
    After doing that, open System Preferences > Users and Groups, choose the user created by Migration Assistant and press the - button to remove it. This is easier if you have an external drive

  • Cannot find Acc when right click

    Well i am trying to convert my mp3 to a Acc and cannot find acc when i right click on the song. Ive tried going into my export and changing it to Acc encoder already and still nothing.

    Leandre22 wrote:
    Well i am trying to convert my mp3 to a Acc
    Why are you trying to convert MP3 to AAC?
    This is not really needed unless you require an AAC file.

  • Warning - Cannot find class de.ewe.ikdb.action.ActionForward

    Hi,
    I'm using external classes e.g. struts as a MVC framework. Using JavaDoc to create the API documentation causes lots of the following warnings:
    warning - Cannot find class de.ewe.ikdb.action.ActionForward
    Actually the class in question is form struts, in the package org.apache.struts.action. As I'm using ant to compile the classes and to generate the documentation so the class path should be ok.
    First I tried the -link option to access the package-list file of struts. This didn't work (but maybe this is a problem due to our firewall).
    So I downloaded the documentation and put it in a local directory and used the -linkoffline option instead. Now the javadoc command works again but I still get these warning messages.
    Does anyone know how to avoid this?
    Regards,
    hedtfeld.

    Hi guys,
    as far as I understand I have to import the classes excplicitly and not with wildcards as my lazy self prefers to do it. It would be nice though to be able to use the wildcard as this is allowed by the java spec ...
    Hope this will help anyone facing the same problem.
    - hedtfeld.

  • Cannot find picture when transferring from Aperture to PSE 11

    Cannot find picture when transferring from Aperture to PSE 11
    I have an older version of PSE and when I transferred a picture from Aperture to PSE9 it would open PSE9 and show the picture.
    I set the Preps in Aperture for PSE 11 and the PSE 11 opens but no picture in the box or photo bin or in the top left "open".
    I changed the Aperture setting to the PSE Organizer and the same thing happened Organizer open BUT there was no picture to be found.
    In Aperture it shows the file being transferred.
    I looked in the PSE 11 preps and file but could not find anything.
    The fact that it opens the PSE 11 app tells me it is being recognized but the picture (file) is going somewhere else.
    Thanks
    Greg

    Hi Greg
      Make sure you are linking to the application in Support Files and not to an alias.

  • Servlet cannot find helper class

    Hello
    Under WEB-INF/classes I put ServletExample and SingletonExample. Compiling ServletExample, that makes use of SingletonExample, works.
    In the directory WEB-INF/classes I also have another direcotry, test. And in WEB-INF/classes/test I put again ServletExample and SingletonExample.
    Here I have tried in several ways to compile the servlet, but I always get an:
    Cannot find symbol class SingletonExample.
    I tried writing package test at the top of both files, and even at the top of only one of these two.
    I even tried to make WEB-INF/classes/test/ServletExample make use of SingletonExample residing in WEB-INF/classes, but I didnt succeded.
    What happens when you have subdirectory in WEB-INF/classes/? I think this is a MUST, to have subdirectory in large webapplication, so I really dont want to put everything in the classes directory.
    Do you how to resolve this prolem? And: if Im in WEB-INF/classes/test and want to referr from a servlet residing in this direcory to a Singleton/helper class residing in WEB-INF/classes/, which approach do I have to use?
    Thanks
    Paolo

    Jeez, you aren't gonna get very far in Java like this.
    CLASSPATH is wrong - again. You're supposed to give JARs and paths where the class loader is supposed to look, not the actual .class file.
    Also, you're not telling the compiler to put the .class file in the package directory structure.
    Your example is pretty awful. Try this:
    Put this code into c:\common
    package common;
    import common.test.TestDown;  // What the hell is this?  There is no package test, but there is a package named common.test
    public class TestUp
       public void sayHello()
          System.out.println("Hello.....");
    }Put this code into c:\common\test
    package common.test;
    import common.TestUp;
    public class  TestDown
       public TestDown()
            TestUp testUp = new TestUp();
            testUp.sayHello();
       public static void main(String[] args)
            new TestDown();
    }Open a command shell and navigate to c:\, then do the following:
    Directory of c:
    07/01/2005  03:43 PM    <DIR>          .
    07/01/2005  03:43 PM    <DIR>          ..
    07/01/2005  03:45 PM    <DIR>          common
                   0 File(s)              0 bytes
                   3 Dir(s)  74,909,675,520 bytes free
    C:\>javac -d . common\*.java
    C:\>javac -d . common\test\*.java
    C:\>java -classpath . common.test.TestDown
    Hello.....Once you've got your head around this, go learn Ant and have it compile your projects properly.
    %

  • Servlet cannot find applet class.. HELP..DONT REPLY..SOLUTION FOUND

    Hi.. can anybody help me.. with this age old problem?
    I have an applet.. which generates a pie chart .. Pie.class. If i embed it in a normal HTML page.. it runs smoothly.
    Now the problem is.. in my servlet i tried to do this
    out.println("<applet code=Pie.class codebase=/mywebapp/  height=300 width=300">);etc..
    but when the servlet runs.. the applet is not initalised .. so instead of having the applet i have a 'x' sign.. .. To diagnose the problem better.. i right click on the area that is supposed to be the applet and select 'Open Java Console' . ..there i see.. a ClassNotFound Exception.
    I have kept the Pie.class in the WEB-INF -> classes Folder ( where all the other class files of the servlets are kept ).
    Can anybody help me??
    Thanks in advance
    Hi guys sorry to bother u.. i have found the soln. myslef... my mistake was to place the applet class in web-inf-> class folder.. as soon as i placed it outside the folder.. it worked superbly. Thanks anyway
    Message was edited by:
    arijit_datta

    me also same problem...
    this class path is included in server itself..
    or we can set during compiling time...
    then this is my compile.bat file please check
    set classpath=%CLASSPATH%; ./WEB-INF/classes;
    @echo off
    javac -d ./WEB-INF/classes/ ./dev/beans/*.java
    javac -d ./WEB-INF/classes/ ./dev/ContentManagement/beans/*.java
    javac -d ./WEB-INF/classes/ ./dev/servlets/*.java
    and my servlet file like this below..
    import java.io.*;
    import javax.servlet.*;
    import javax.servlet.http.*;
    import com.deploy.servlet.*;
    public class ControlServlet extends HttpServlet
         public void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException,IOException
              response.setContentType("text/html");
              PrintWriter out = response.getWriter();
              out.println("Testing");
    /*          if (request.getParameter("pageName")=="CEOSpeak")
                   CEOBean CB = new CEOBean();
                   if (request.getParameter("actionType")=="add")
                   else if (request.getParameter("actionType")=="edit")
                   else if (request.getParameter("actionType")=="delete")
                        if(CB.deleteCEO(request.getParameter("CEOId")))
                             response.sendRedirect("CEO_Speaks.jsp");

Maybe you are looking for

  • XML Deserialization error while consuming Enterprise service in wd java..

    Hello, I am trying to build 2 webdynpro java webdynpro applications which consumes enterprise service for purchase order and another application for Busines partner. While i was able to successfully consume the PO service in webdynpro java and get th

  • Windows 8 single language iso

    I have a hp pavilion 15-Eo15TX with pre installed windows 8 single language. After updating to windows 8.1 ,i had several issues and got BSOD several times .Then i refreshed the PC. Even after refreshing the pc i got BSOD multiple times ,then i  had

  • Serialized item stock discrepency

    Hi, For a material in MMBE it shows stock has 10 nos. If I see it in IQ09 serial number report for the same article it shows 11. How it can be possible Pls advise

  • Unicode hex conversion

    Hello, can anyone please tell me how to achieve the same effect on this website, http://mylanguages.org/converter.php , in pl sql or oracle sql? They have taken an arabic string and returned a (to my knowledge) hex value. Many Thanks

  • Eraser Tool and Pattern Stamp Tools Not Working Properly

    I recently downloaded Photoshop CC on my Mac.  I've been using Photoshop for years and don't recall experiencing these problems. When using the eraser tool in brush mode, I select the appropriate preset and opacity, flow etc. Let's say I have the bru