Posted By:
Sergi_Arrufat
Posted On:
Thursday, April 19, 2001 02:23 AM
All depends on the application server you are using. This is an example extracted from a jBoss client application:
System.setProperty("java.naming.factory.initial", "org.jnp.interfaces.NamingContextFactory");
System.setProperty("java.naming.provider.url", "myhost");
javax.naming.Context jndiContext = new javax.naming.InitialContext();
Object objref = jndiContext.lookup("ejb/MyBean");