This content has been marked as final.
Show 1 reply
-
1. Re: newbie wants JNDI InitialContext
admiyo Apr 17, 2002 5:41 PM (in response to nlessmann)Do you have JBoss running?
This is my Basic code:
Properties props = new Properties();
props.put("java.naming.factory.initial",
"org.jnp.interfaces.NamingContextFactory");
props.put("java.naming.provider.url"
,"localhost:1099");
System.getProperties().putAll(props);
InitialContext jndiContext = new InitialContext();
Object ref = jndiContext.lookup("Agency");
agencyHome = (AgencyHome) PortableRemoteObject.narrow (ref, AgencyHome.class);