File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
Win a copy of Clojure in Action this week in the Clojure forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Getting problem in struts

 
Gourav Bansal
Ranch Hand
Posts: 43
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hiii i am new to the struts
i got the error while running the application

success.jsp(Where i got the error)


CustomTagMappingFile.tld









ERROR IS


 
Gourav Bansal
Ranch Hand
Posts: 43
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Problem Solved..........




 
David Newton
Author
Rancher
Posts: 12617
IntelliJ IDE Ruby
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
It's good to follow up with what solved your problem so others with similar issues can gain from your experience.

Also, it's conventional to name packages with all lower-case letters; following Java programming conventions makes your code easier to understand.

Glad you worked it out!
 
Gourav Bansal
Ranch Hand
Posts: 43
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks for the suggestion DAVID
i will take of that in future

now i get into another problem
when i run my application means homepage and leave the field blank then i redirect to the home page with proper error massage
i am redirected to the home page but no message is displayed
here is my homepage




and this my new ActionForm Class



MY Property File

 
Gourav Bansal
Ranch Hand
Posts: 43
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hiiii

please suggest me any solution

even when i use the



it gives me null pointer exception

i think problem is in the resource bundle

please please look into it



 
David Newton
Author
Rancher
Posts: 12617
IntelliJ IDE Ruby
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Well, you don't have that key in your resources file, unless you only posted part of it, which wouldn't be very helpful. I wouldn't think that would cause an NPE, though, but you also don't post the stack trace.
 
Gourav Bansal
Ranch Hand
Posts: 43
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
here is the stack trace



and here is my property file

 
mahesh shinde
Ranch Hand
Posts: 69
Eclipse IDE Firefox Browser Ubuntu
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
have you registered resource bundle in strutsconfig.xml?
 
Gourav Bansal
Ranch Hand
Posts: 43
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
yes i done it

 
Gourav Bansal
Ranch Hand
Posts: 43
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
please look into it

i stuck into this since morning


 
David Newton
Author
Rancher
Posts: 12617
IntelliJ IDE Ruby
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Please show the deployed directory/file tree. (Do not post an image.)
 
mahesh shinde
Ranch Hand
Posts: 69
Eclipse IDE Firefox Browser Ubuntu
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
resource bundle is in WEB-INF folder or any other folder
 
Gourav Bansal
Ranch Hand
Posts: 43
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
i have created a folder resource in which i am keeping the file
and give the path of folder in the classpath
 
Prakash Mani - Attur
Ranch Hand
Posts: 100
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
you keep the same folder under classes directory...
 
Gourav Bansal
Ranch Hand
Posts: 43
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
problem solved

i create a new pakage and keep that resource bundle file in that

thanks to all

 
Bhupeshy Yadav
Greenhorn
Posts: 5
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
getting below exception........
org.apache.jasper.JasperException
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:346)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:292)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:236)
javax.servlet.http.HttpServlet.service(HttpServlet.java:810)


root cause

java.lang.NullPointerException
org.apache.struts.taglib.TagUtils.retrieveMessageResources(TagUtils.java:1175)
org.apache.struts.taglib.TagUtils.message(TagUtils.java:1038)
org.apache.struts.taglib.bean.MessageTag.doStartTag(MessageTag.java:224)
org.apache.jsp.index_jsp._jspx_meth_bean_message_0(index_jsp.java:149)
org.apache.jsp.index_jsp._jspx_meth_html_html_0(index_jsp.java:114)
org.apache.jsp.index_jsp._jspService(index_jsp.java:77)
org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:94)
javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:298)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:292)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:236)
javax.servlet.http.HttpServlet.service(HttpServlet.java:810)

 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic