Hi, i have been using and working with ejbs from a java client calling ejbs from the server that comes with the j2ee package . But now i wish to call the ejbs from a servlet within tomcat. I have put all the jar files for the client that is needed it to the lib dir of my web application but i keep getting the exception
javax.naming.NameNotFoundException: Name test is not bound in this Context where test is my JNDI name for the bean. This code works for the java client so i am wondering do i have to add anything to the server.xml file or something????? Heres my servlet code: try{ Properties prop = new Properties(); prop.put(Context.PROVIDER_URL,"localhost:1050"); Context context= new InitialContext(); Object ob = context.lookup("test"); MyBeanHome home = (MyBeanHome)PortableRemoteObject.narrow(ob, MyBeanHome.class); MyBean my = home.create(); message = my.getString(); System.out.println("result : "+message); } catch(Exception e){ e.printStackTrace(); } -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>