This week's book giveaway is in the OCMJEA forum.
We're giving away four copies of OCM Java EE 6 Enterprise Architect Exam Guide and have Paul Allen & Joseph Bambara on-line!
See this thread for details.
The moose likes Struts and the fly likes Exception: Servlet.service() for servlet jsp threw exception Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of OCM Java EE 6 Enterprise Architect Exam Guide this week in the OCMJEA forum!
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "Exception: Servlet.service() for servlet jsp threw exception" Watch "Exception: Servlet.service() for servlet jsp threw exception" New topic
Author

Exception: Servlet.service() for servlet jsp threw exception

ashwini hikulkarni
Greenhorn

Joined: Jun 16, 2008
Posts: 25
Hi all
please help me to resolve the error related to jsp , I would be thankful to you
warm regards

Error is
16:47:04,209 ERROR [[jsp]] Servlet.service() for servlet jsp threw exception
java.lang.NullPointerException
at org.apache.jsp.uploadHistory_jsp._jspService(org.apache.jsp.uploadHistory_jsp:96)
at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:97)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:322)
at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314)
at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:810)

I am posting my JSP and Servlet kindly help me please

JSP CODE where i want to see the retrived data from database



MY ACTIONSERVLET
Sagar Rohankar
Ranch Hand

Joined: Feb 19, 2008
Posts: 2902
    
    1

I think , the problem is here !!



and you are storing the request objects attribute like this :



Change it to proper name, and try !!


[LEARNING bLOG] | [Freelance Web Designer] | [and "Rohan" is part of my surname]
ashwini hikulkarni
Greenhorn

Joined: Jun 16, 2008
Posts: 25
thanks for responding

but sagar every thing is mapped clearly.. even though it is showing error

Adding to this i would also post my Upload Services.java



please respond
Sagar Rohankar
Ranch Hand

Joined: Feb 19, 2008
Posts: 2902
    
    1



Pl check the fileList object you are getting is null on not !!
ashwini hikulkarni
Greenhorn

Joined: Jun 16, 2008
Posts: 25
yes it is getting
null
Sagar Rohankar
Ranch Hand

Joined: Feb 19, 2008
Posts: 2902
    
    1

So , How can you call a method on null object, it certainly gonna throw a NullPointerException, so find out why its set to null in your Action Class .
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Exception: Servlet.service() for servlet jsp threw exception