EJB发布,帮我一把
Tiack 2004-03-19 09:44:01 用J2EE来发布一个简单EJB,功能很简单,但老是在Client程序上出错:
InitialContext init = new InitialContext();
Object homeObject = init.lookup("JNDIName");
TextHome home = (TextHome)PortableRemoteObject.narrow(homeObject, TextHome.class);
在此就出错了.
javax.naming.NoInitialContextException: Need to specify class name in environment or system property, or as an applet parameter, or in an aplication resource file: java.naming.factory.initial.....还有好多
可是我将client jar文件放在classpath中了,为什么还会出这错,晕...
----------------------------------------