Can't find javax.ejb

Our instructor has given us a sample program that demonstrates ejbs.
I could get it to run on the school computer but when I try at home I get the error:
C:\includeEJB>c:\Java\bin\javac @HelloEJBOptions @HelloEJBclasses
HelloEJB\ejb\Hello.java:13: package javax.ejb does not exist
public interface Hello extends javax.ejb.EJBObject
^
The instructor has us compile the code with the following batch file:
:: Compiling EJB code
c:\Java\bin\javac @HelloEJBoptions @HelloEJBclasses
:: creating the JAR file
cd HelloEJB
c:\Java\bin\jar -cf  ..\Hello\HelloEJB.jar *
cd ..
:: Compiling Web code
c:\Java\bin\javac @HelloWeboptions @HelloWebclasses
:: creating the WAR file
cd HelloWeb\web
c:\Java\bin\jar -cf  ..\..\Hello\HelloWeb.war *
:: creating the EAR file
cd ..\..\Hello
c:\Java\bin\jar -cf  ..\Hello.ear *
cd ..
pauseI believe the school computer uses j2se sdk 1.4.2 and that's what I have installed on my computer.
I believe the error I am getting is saying that the compiler can't find the javax.ejb class. Is this a correct assumption?
If so, why? Do I have the wrong java version? Does it have to do with the classpath? I am at a loss and have tried downloading j2se sdk 1.5 and j2ee sdk 1.4 and still get the same error.
Any help would be appreciated.

I am still trying to find the package javax.ejb. Can anyone please explain what directory I would find this package. I can find the javax directory but I don't see the ejb package included. Should it be listed where I can see it,, or is it something that is down in the directory further? If it should be present in the javax package and I'm not seeing it, can I download just that package from somewhere?
Thanks in advance for any help. I'm sure that I'm doing something basic wrong so please don't be afraid to give me the most basic help. I have tried downloading J2SE SDK 1.4.2, J2SE SDK 1.5, and J2EE SDK 1.4 and always get the error saying the compiler can' find javax.ejb.
I'm almost positive the code is fine because it ran on the school computer, but I'm still not ruling that out.

Similar Messages

  • In jb6,It can not find javax.ejb,how can i do?

    I want to use jb6 to develop ejb beans ,
    but In my jb6,when I complile,It show "can't acess javax/ejb",and i can't find ejb in javax,how can i do?
    where ejb?

    I want to use jb6 to develop ejb beans ,
    but In my jb6,when I complile,It show "can't acess
    javax/ejb",and i can't find ejb in javax,how can i
    do?
    where ejb?Its not required to set any environment variable for EJB development with JBuilder6. If you are not using any of the JBuilder wizards for creating EJB's, then you need to add your JAR files through 'required libraries'.

  • J2EE setup - Can't find javax.ejb.EJBObject

    I am running my first client side program and the below error is being returned:
    Exception in thread "main" java.lang.NoClassDefFoundError:javax/ejb/EJBObject.
    I am guessing that my classpath to find
    javax.ejb.EJBObject is not setup properly. Does
    anyone know how it should be set. I am using J2EE.

    Apparently there is a better solution from previous post:
    classpath=.;..;c:\jdkee1.3\lib\j2ee.jar;
    If you specify a directory, Java will search for class files in that directory; if you specify an archive (zip or jar) Java will search for class files in the archive. The class files you need reside in the two archives c:\jdk1.3\lib\rt.jar and c:\jdkee1.3\lib\j2ee.jar.

  • Can not find javax.ejb.CreateException when lookup and create EJB instance.

    Hi,
        I installed SAP CE 7.2 and NWDS 7.2. When i call create() of EJB's home interface from JAVA stand alone app to create EJB instance, the complier state that it need  'javax.ejb.CreateException'. How can i find the jar that contain 'javax.ejb.CreateException' to solve this problem?
    Thank a lot,
    Thongie
    Edited by: Thongie on Jul 8, 2011 7:30 PM

    Thank a lot, I can found EJB20.jar at 'usr\sap\<sid>\<instance_id>\j2ee\j2eeclient\'

  • SOS!! : I can't find javax.rmi.*

    After i install j2sdkee1.2.1,
    I can't find javax.rmi.* in the dictory D:\j2sdkee1.2.1\lib
    Where will i find it and download it into my computer

    Add j2ee.jar to your classpath.
    Jesper

  • Cannot find javax.ejb.CreateException fix classpath

    Hi Guys,
    I have made a Webdynpro in which I am using an EJB in the libraries of the project. When I access the classes of EJB I am getting a complie time error saying
    Cannot find class file for javax.ejb.CreateException. Fix the classpath then try rebuilding this project.
    Can you tell me how to fix this.
    Regards,
    Khusro Habib

    Hi,
    Guys I was able to solve this problem, by adding
    C:\Program Files\SAP\IDE\IDE70\eclipse\plugins\com.tssap.ext.libs.j2ee_1.3.0\lib\ejb20.jar
    into the project properties>> in the Java Buildpath adding external jars.
    Khusro Habib

  • Can�t find javax classes??

    I resently installed jdk 1.4 to my win XP and it�s working fine except for all the javax classes that the system can�t find. Do I need to define a path or something to find these?

    But I cleared my system of old jdks before I installed
    the new.. Shouldn�t that be enough? The java console
    says version 1.4. Is the javax classes included in the
    jdk package?Which javax packages? Some of them (such as javax.ejb) belong to J2EE (enterprise edition), not to the J2SE (standard edition JDK).

  • Where can i find "javax.xml.parsers"

    Hello Every One, H R U Doing
    I wan 2 parse XML data in JAVA Application, i found an example which was quite clear but that example uses
    import javax.xml.parsers.*;
    But at compile time exception is thrown that this package does not exist,
    Please tell me where can i find this package.
    Thanx in Advance,
    Azhar Javaid

    It's in the jaxp-api.jar from the JAXP installation.

  • Where can i find javax.servlet.http.httpServletRequest in weblogic jars

    Hi,
    i'm migrating from weblogic 8 to weblogic 10.3.
    in my java codes, i use import javax.servlet.http.httpServletRequest. Previously this package can in found in weblogic.jar in weblogic 8.
    However weblogic.jar for 10.3 does not have this package. Where can i find this package?
    Thanks

    oh i see. the api.jar has the indicate the path to the servlet package.
    /modules/javax.servlet_1.0.0.0-2-5.jar.
    Thanks for the guidance.:)

  • Can not find my EJB's from my Servlet

    Hi
    I am new to EJB and am trying to get a Servlet to call some sessionless EJB beans. I have got it working in JDeveloper but when I deploy it to orion application server I keep getting a javax.naming.NameNotFoundException exception throw from the Servlet when it tries to find the first EJB.
    The code in the Servlet is:
    env.put(Context.INITIAL_CONTEXT_FACTORY, "com.evermind.server.rmi.RMIInitialContextFactory");
    env.put(Context.SECURITY_PRINCIPAL, "admin");
    env.put(Context.SECURITY_CREDENTIALS, "jewels");
    // env.put(Context.PROVIDER_URL, "ormi://localhost:23891/current-workspace-app");
    env.put(Context.PROVIDER_URL, "ormi://localhost:23791/dev");
    Context ctx = new InitialContext(env);
    System.out.println("Getting mapping class ejb");
    //mapping
    ExponentMappingServiceHome mappingHome = (ExponentMappingServiceHome)ctx.lookup("ExponentMappingServiceHome");
    ExponentMappingService mapping = mappingHome.create();
    My EJB xml looks like this:
    <?xml version = '1.0' encoding = 'windows-1252'?>
    <!DOCTYPE ejb-jar PUBLIC "-//Sun Microsystems, Inc.//DTD Enterprise JavaBeans 1.1//EN" "http://java.sun.com/j2ee/dtds/ejb-jar_1_1.dtd">
    <ejb-jar>
    <enterprise-beans>
    <session>
    <description>Session Bean ( Stateless )</description>
    <display-name>ExponentMappingService</display-name>
    <ejb-name>ExponentMappingService</ejb-name>
    <home>com.exponent.ejb.service.map.ExponentMappingServiceHome</home>
    <remote>com.exponent.ejb.service.map.ExponentMappingService</remote>
    <ejb-class>com.exponent.ejb.service.map.ExponentMappingServiceBean</ejb-class>
    <session-type>Stateless</session-type>
    <transaction-type>Container</transaction-type>
    </session>
    <session>
    <description>Session Bean ( Stateless )</description>
    <display-name>ExponentMappingViewsService</display-name>
    <ejb-name>ExponentMappingViewsService</ejb-name>
    <home>com.exponent.ejb.service.map.ExponentMappingViewsServiceHome</home>
    <remote>com.exponent.ejb.service.map.ExponentMappingViewsService</remote>
    <ejb-class>com.exponent.ejb.service.map.ExponentMappingViewsServiceBean</ejb-class>
    <session-type>Stateless</session-type>
    <transaction-type>Container</transaction-type>
    </session>
    <session>
    <description>Session Bean ( Stateless )</description>
    <display-name>FalconService</display-name>
    <ejb-name>FalconService</ejb-name>
    <home>com.exponent.ejb.service.FalconServiceHome</home>
    <remote>com.exponent.ejb.service.FalconService</remote>
    <ejb-class>com.exponent.ejb.service.FalconServiceBean</ejb-class>
    <session-type>Stateless</session-type>
    <transaction-type>Container</transaction-type>
    </session>
    </enterprise-beans>
    </ejb-jar>
    I have been trying for a while to get the JNDI naming right but everything I try gets the above error. Any help would be great.
    Thanks
    Andre

    You have to lookup for "ExponentMappingService", and not "ExponentMappingServiceHome"
    The name you give in the <ejb-name> tag in ejb-jar.xml is the JNDI name of the EJB. This is the name u have to look up.

  • Where can I find javax.wireless.messaging

    Hello,
    I am trying to fellow the tutorial ( http://developers.sun.com/mobility/midp/articles/wma/ ) about sending SMS. I think I need a package called javax.wireless.messaging. Do you know where I can find this?

    The JSR is the source of the original proposal
    [http://jcp.org/en/jsr/detail?id=120]
    It is an API specification so you need the API and an actual implementation as well.
    The above has a reference implementation. A "reference implementation" is intended to demonstrate that the API is sufficient. It isn't intended to be a production implementation and there might be problems with it.
    Note that the API is not part of the Java API. Including 1.7
    That above url via the "Final Release 2" suggests that Sun has a real implementation (alternative to the reference). Probably commercial. There might be other implementations as well.

  • Tomcat 5 can�t find javax.servlet.http.HttpServlet

    Hi.
    I don�t know if this is a simple question or not, but i didn�t find anything solving this problem and
    i�m new to tomcat......
    I�m trying to deploy my web application in my system. (Windows XP , j2sdk1.4.2_02, jakarta Tomcat 5, jakarta struts 1.1 and jakarta taglibs 1.1).No problems while compiling the .java classes and checked all the .jar files that my application needs to work (or that is what I think). I expand my .war file at /webapps on tomcat directory and startup Tomcat. Tomcat starts up but while starting I get the following errors...
    17-feb-2004 17:58:50 org.apache.coyote.http11.Http11Protocol init
    INFO: Initializing Coyote HTTP/1.1 on port 8080
    17-feb-2004 17:58:51 org.apache.catalina.startup.Catalina load
    INFO: Initialization processed in 4948 ms
    17-feb-2004 17:58:51 org.apache.catalina.core.StandardService start
    INFO: Starting service Catalina
    17-feb-2004 17:58:51 org.apache.catalina.core.StandardEngine start
    INFO: Starting Servlet Engine: Apache Tomcat/5.0.18
    17-feb-2004 17:58:51 org.apache.catalina.core.StandardHost start
    INFO: XML validation disabled
    17-feb-2004 17:58:51 org.apache.catalina.core.StandardHost getDeployer
    INFO: Create Host deployer for direct deployment ( non-jmx )
    17-feb-2004 17:58:51 org.apache.catalina.core.StandardHostDeployer install
    INFO: Processing Context configuration file URL file:C:\softProyecto\Tomcat5\conf\Catalina\localhost\admin.xml
    17-feb-2004 17:58:55 org.apache.commons.digester.Digester endElement
    GRAVE: End event threw exception
    java.lang.reflect.InvocationTargetException
         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
         at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:324)
         at org.apache.commons.beanutils.MethodUtils.invokeMethod(MethodUtils.java:252)
         at org.apache.commons.digester.SetNextRule.end(SetNextRule.java:256)
         at org.apache.commons.digester.Rule.end(Rule.java:276)
         at org.apache.commons.digester.Digester.endElement(Digester.java:1058)
         at org.apache.catalina.util.CatalinaDigester.endElement(CatalinaDigester.java:123)
         at org.apache.xerces.parsers.AbstractSAXParser.endElement(Unknown Source)
         at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanEndElement(Unknown Source)
         at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(Unknown Source)
         at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source)
         at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
         at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
         at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
         at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source)
         at org.apache.commons.digester.Digester.parse(Digester.java:1567)
         at org.apache.catalina.core.StandardHostDeployer.install(StandardHostDeployer.java:520)
         at org.apache.catalina.core.StandardHost.install(StandardHost.java:906)
         at org.apache.catalina.startup.HostConfig.deployDescriptors(HostConfig.java:527)
         at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:472)
         at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1008)
         at org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:394)
         at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:166)
         at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1133)
         at org.apache.catalina.core.StandardHost.start(StandardHost.java:832)
         at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1125)
         at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:518)
         at org.apache.catalina.core.StandardService.start(StandardService.java:519)
         at org.apache.catalina.core.StandardServer.start(StandardServer.java:2345)
         at org.apache.catalina.startup.Catalina.start(Catalina.java:598)
         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
         at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:324)
         at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:297)
         at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:398)
    Caused by: java.lang.NoClassDefFoundError: javax/servlet/http/HttpServlet
         at java.lang.ClassLoader.defineClass0(Native Method)
         at java.lang.ClassLoader.defineClass(ClassLoader.java:537)
    it seems like C:\softProyecto\Tomcat5\conf\Catalina\localhost\admin.xml (C:\softproyecto\tomcat5 = tomcat�s home directory) needs javax.servlet.http.HttpServlet. And that comes from a Tomcat .jar file, i think.
    After more and more messages..... here it comes my application (MapasRuido)...which needs javax.servlet.http.HttpServlet and compiled ok at compiling time!
    INFO: Installing web application at context path /MapasRuido from URL file:C:\softProyecto\Tomcat5\webapps\MapasRuido
    17-feb-2004 18:02:48 org.apache.catalina.startup.HostConfig deployDirectories
    GRAVE: Error durante el despliegue del directorio MapasRuido de la aplicaci�n web
    java.lang.NoClassDefFoundError: javax/servlet/http/HttpServlet
         at java.lang.ClassLoader.defineClass0(Native Method)
         at java.lang.ClassLoader.defineClass(ClassLoader.java:537)
         at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:123)
         at java.net.URLClassLoader.defineClass(URLClassLoader.java:251)
         at java.net.URLClassLoader.access$100(URLClassLoader.java:55)
         at java.net.URLClassLoader$1.run(URLClassLoader.java:194)
         at java.security.AccessController.doPrivileged(Native Method)
         at java.net.URLClassLoader.findClass(URLClassLoader.java:187)
         at java.lang.ClassLoader.loadClass(ClassLoader.java:289)
         at java.lang.ClassLoader.loadClass(ClassLoader.java:282)
         at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:274)
         at java.lang.ClassLoader.loadClass(ClassLoader.java:235)
         at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1296)
         at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1230)
         at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:302)
         at java.lang.ClassLoader.defineClass0(Native Method)
         at java.lang.ClassLoader.defineClass(ClassLoader.java:537)
         at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:123)
         at org.apache.catalina.loader.WebappClassLoader.findClassInternal(WebappClassLoader.java:1677)
         at org.apache.catalina.loader.WebappClassLoader.findClass(WebappClassLoader.java:900)
         at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1350)
         at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1230)
         at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:302)
         at java.lang.ClassLoader.defineClass0(Native Method)
         at java.lang.ClassLoader.defineClass(ClassLoader.java:537)
         at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:123)
         at org.apache.catalina.loader.WebappClassLoader.findClassInternal(WebappClassLoader.java:1677)
         at org.apache.catalina.loader.WebappClassLoader.findClass(WebappClassLoader.java:900)
         at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1350)
         at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1230)
         at org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:979)
         at org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:887)
         at org.apache.catalina.core.StandardContext.loadOnStartup(StandardContext.java:3960)
         at org.apache.catalina.core.StandardContext.start(StandardContext.java:4283)
         at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:866)
         at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:850)
         at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:638)
         at org.apache.catalina.core.StandardHostDeployer.install(StandardHostDeployer.java:320)
         at org.apache.catalina.core.StandardHost.install(StandardHost.java:875)
         at org.apache.catalina.startup.HostConfig.deployDirectories(HostConfig.java:727)
         at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:477)
         at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1008)
         at org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:394)
         at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:166)
         at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1133)
         at org.apache.catalina.core.StandardHost.start(StandardHost.java:832)
         at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1125)
         at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:518)
         at org.apache.catalina.core.StandardService.start(StandardService.java:519)
         at org.apache.catalina.core.StandardServer.start(StandardServer.java:2345)
         at org.apache.catalina.startup.Catalina.start(Catalina.java:598)
         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
         at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:324)
         at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:297)
         at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:398)
    17-feb-2004 18:02:48 org.apache.catalina.core.StandardHostDeployer install
    INFO: Installing web application at context path from URL file:C:\softProyecto\Tomcat5\webapps\ROOT
    17-feb-2004 18:02:48 org.apache.catalina.core.StandardHostDeployer install
    INFO: Installing web application at context path /servlets-examples from URL file:C:\softProyecto\Tomcat5\webapps\servlets-examples
    17-feb-2004 18:02:48 org.apache.catalina.core.StandardHostDeployer install
    INFO: Installing web application at context path /tomcat-docs from URL file:C:\softProyecto\Tomcat5\webapps\tomcat-docs
    17-feb-2004 18:02:49 org.apache.coyote.http11.Http11Protocol start
    INFO: Starting Coyote HTTP/1.1 on port 8080
    tomcat�s web applications servlets-examples and tomcat-docs work fine, but my application doesn�t. Is there any relation between those errors? any idea about what happens?
    Thank you in advance.

    "...The CLASSPATH is ignored by Tomcat, of course. AND javac. AND java. AND Eclipse. AND NetBeans. AND JBuilder. And just about everything else in the Java universe..."
    What I mean by this, of course, is that each of these requires you to set the CLASSPATH in the way they expect. None of them even looks for a system environment variable named CLASSPATH. You can waste a lot of time thinking that your CLASSPATH is "all set", but it's not.
    Tomcat assumes the following for your Web app's CLASSPATH:
    (0) The JDK rt.jar, of course,
    (1) All the JARs in TOMCAT_HOME/common/lib,
    (2) All the JARs in your WEB-INF/lib,
    (3) All the .class files in your WEB-INF/classes
    That's it. (Maybe one or two others, but those are the important ones.)
    Eclipse and NetBeans have their own way to set CLASSPATH for each project. You'll have to learn how for those IDEs.
    The CLASSPATH is still vitally important. The system environment variable just isn't part of it. - MOD

  • Why i can't find the ejb-container?

    integrate jb4 and wl6.0
    after i follow the step by step as the aritcle
    http://community.borland.com/article/0,1410,26796,00.html said
    when i use EJB deployment to deploy my jar to the weblogic server(at maybe
    the last step),it report no application server started but i already ran
    it.i don't know how to solve it,can any guru help me?thanx in advance.
    another question,is it should
    -Dweblogic.system.home=d:/bea/wlserver6.0
    or -Dweblogic.RootDirectory=d:/bea/wlserver6.0 in the vm?
    and what is the difference of it?

    I had tried to set up the connection via usinb a powered usb hub as the bridge between external HDD and the airport extreme. i still cannot found the HDD in the "airport utilities".
    This is my setting.
    1. Set airport extreme  as "sharing-single-ip" mode. The wireless network functions correctly.
    2. Connect external HDD to MBA. Partition it into single-partition with Mac OS extended (journaled).
    3. The HDD can be found if i plugged it directly to my MBA.
    4. Connect a powered usb hub to airport extreme.
    5. Connect external HDD to the powered usb hub.
    6. Open airport utilities.
         a. Select "airport extreme" in the sidebar.
         b. Change the "Disks" sheet.
    7. Cannot find an external Disk
    Is there any problem here?
    Please help me. Thanks a lot!!

  • Can't find javax.faces.context.FacesContext

    Hi,
    I have strange problem since morning. I am using Jdeveloper 10.1.3 ADF BC
    I have been using the below code successfully. But today all of a sudden everything is pointing to the wrong import
    // 1. Access the FacesContext
    FacesContext fc = javax.faces.context.FacesContext.getCurrentInstance();
    // 2. Create value binding for the #{data} EL expression
    ValueBinding vb = fc.getApplication().createValueBinding("#{data}");
    // 3. Evaluate the value binding, casting the result to BindingContext
    BindingContext bc = (BindingContext)vb.getValue(fc);
    // 4. Find the data control by name from the binding context
    DCDataControl dc = bc.findDataControl("AppModuleDataControl");
    For eg: FacesContext instead of fetching from javax.faces.context is getting FacesContext from com.sun.Faces
    DCIteratorBinding is going to oracle.jbo.uicli.binding.JUIteratorBinding instead of oracle.adf.model.binding even if i have imported it in the class. Should i start all over again.
    Please Help.
    Thanks in advance

    ADF BC isn't relevant here. However JSF is. What JSF component set are you using? Pure JSF components or ADF Faces?
    I suggest (or guess) what's happened is at some point you were using JSF only components, and the project was configured to use the pure JSF classes. However at some point you've brought in an ADF Faces component as well, and now its switched over to using the super ADF Faces classes instead.
    Does this make sense?
    Regards,
    CM.

  • Can't find javax when building...

    I'm useing JBuilder and when I compile, the system can't locate the javax directories. Do I need to set something in the classpath to point to some jar file?

    That's really odd. JBuilder should pick up the swing packages, at least it does in my 3.5 and 3.0 version.
    Try reinstalling it because JBuilder automatically sets the path settings that you would have to deal with.

Maybe you are looking for