Granny's Programming Pearls
"inside of every large program is a small program struggling to get out"
JavaRanch.com/granny.jsp
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

getting exception

 
Naresh Chaurasia
Ranch Hand
Posts: 361
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
when i am trying to run the first program for hf ejb i am getting the followig error:

e=javax.naming.NoInitialContextException: Need to specify class name in environm
ent or system property, or as an applet parameter, or in an application resource
file: java.naming.factory.initial
javax.naming.NoInitialContextException: Need to specify class name in environmen
t or system property, or as an applet parameter, or in an application resource f
ile: java.naming.factory.initial
at javax.naming.spi.NamingManager.getInitialContext(NamingManager.java:6
40)
at javax.naming.InitialContext.getDefaultInitCtx(InitialContext.java:243
)
at javax.naming.InitialContext.getURLOrDefaultInitCtx(InitialContext.jav
a:280)
at javax.naming.InitialContext.lookup(InitialContext.java:347)
at callingEJB.main(callingEJB.java:24)


----------------------------------------------------------
any help will be appreciated.

thnx
 
Jesus Angeles
Ranch Hand
Posts: 2068
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi, can you post the jndi lookup code
 
Valentin Crettaz
Gold Digger
Sheriff
Posts: 7610
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The following post explains how to get rid of this problem:
http://www.coderanch.com/t/160390/java-EJB-SCBCD/certification/Chap-AdviceBean-HF-EJB
 
Naresh Chaurasia
Ranch Hand
Posts: 361
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
thnx Valentin,it works.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic