----------------------------- Please read the FAQ! <http://java.apache.org/faq/> ----------------------------- Greetings... I have written a JSP (listed below) to request an entity bean from Weblogic server. The page displays only "Getting context Unable to find Savings. is server up?" I am using Apache 1.3.6, JServ 1.0, GNUJSP 0.91 and Weblogic 4.0.3. How do I make this page works? <html> <body> <h2> EJB Test Using JSP </h2> <p> <%@ import="java.util.*" %> <%@ import="javax.ejb.*" %> <%@ import="javax.naming.*" %> <%@ import="java.rmi.RemoteException" %> <%@ import="demo.*" %> <% try { Hashtable h = new Hashtable(); h.put(Context.INITIAL_CONTEXT_FACTORY, "weblogic.jndi.WLInitialContextFactory"); h.put(Context.PROVIDER_URL, "t3://nucleus1:7001"); out.println("Getting context"); Context ctx = new InitialContext(h); out.println("Lookup..."); SavingsHome home = (SavingsHome) ctx.lookup("Savings"); out.println("findind..."); Savings ac = home.findByPrimaryKey(new SavingsPK(102)); out.println(ac.getName()); } catch (NamingException nameExp) {out.println("Unable to find Savings. is server up?");} catch (FinderException findExp) {out.println("Unable to find 102");} catch (RemoteException remExp) {out.println("Remote exception has occured");} %> </p> </body> </html> -- -------------------------------------------------------------- Please read the FAQ! <http://java.apache.org/faq/> To subscribe: [EMAIL PROTECTED] To unsubscribe: [EMAIL PROTECTED] Archives and Other: <http://java.apache.org/main/mail.html/> Problems?: [EMAIL PROTECTED]
