The moose likes EJB and Other Java EE Technologies and the fly likes EJB 2.1: NullPointException Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login
JavaRanch » Java Forums » Java » EJB and Other Java EE Technologies
Reply Bookmark "EJB 2.1: NullPointException" Watch "EJB 2.1: NullPointException" New topic
Author

EJB 2.1: NullPointException

Yohan Weerasinghe
Ranch Hand

Joined: Oct 07, 2010
Posts: 403

Hi,

I am using netbeans to develop my applications. Whenever I deploy the application and view it from the browser and access the related servlet through the HTML, it is giving me "NullPointException". I am u8sing GlassFish server 3.1. All the details are below

LoanBean.java





LoanBeanRemote.java





LoanBeanRemoteHome.java




LoanBeanServlet.java




index.html



ejb-jar.xml



glassfish-web.xml



I am attaching a screenshot of the error I get. Please help me


[Thumb - Untitled.png]
 Filename Untitled.png [Disk] Download
 Description
 Filesize 21 Kbytes
 Downloaded:  2 time(s)


Are you better than me? Then please show me my mistakes..
Yohan Weerasinghe
Ranch Hand

Joined: Oct 07, 2010
Posts: 403

help please
Yohan Weerasinghe
Ranch Hand

Joined: Oct 07, 2010
Posts: 403

My problem is solved. There were few errors

1. <input type="text" accept="time"/> as you can see I have given the attribute "accept" except "name"
2. I had to remove the unnecessary white spaces using trim() method java when the data are submitted to the servlet
3. Had to replace the JNDI name with the correct one which is automatically assigned by the container. That name was in "glasfish-jar-xml.xml" (or something similar) file

Marking this thread as solved
 
 
subject: EJB 2.1: NullPointException
 
Threads others viewed
whilst fooling around with SessionId and cookies...
help with client error
embedded js file in doGet
Connection Pooling
Passing more than one object between jsp and servlet
developer file tools