2 Replies Latest reply on Aug 24, 2007 10:25 AM by A dddddd

    Basic EJB3 with JBOSS

    A dddddd Newbie

      I have jboss 4.2.1 GA with Eclipse 5.5 and trying to run the calculator example given on the jboss site. I have created the bin and here is my client:
      public static void main(String[] args) {
      try {

      Context context=new InitialContext();
      AdviceRemote bean = ( AdviceRemote) context.lookup("com.andy.ejb3.AdviceRemote/remote");
      } catch (NamingException e) {

      javax.naming.NoInitialContextException: Need to specify class name in environment or system property, or as an applet parameter, or in an application resource file: java.naming.factory.initial

      If I use something like,


      Context context=new InitialContext(properties);

      I get:
      javax.naming.NoInitialContextException: Cannot instantiate class: org.jnp.interfaces.NamingContextFactory [Root exception is java.lang.ClassNotFoundException:

      Please help!