aspose file tools*
The moose likes Struts and the fly likes Struts 1.3 Validation Problem Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "Struts 1.3 Validation Problem" Watch "Struts 1.3 Validation Problem" New topic
Author

Struts 1.3 Validation Problem

Mark Butcher
Ranch Hand

Joined: Jun 28, 2012
Posts: 46
Hi Guyz,

I get the following error on browser when I try to open the login page of my application :

java.lang.NullPointerException: Depends string "required" was not found in validator-rules.xml

Kindly help.
Thanks,
Mark.


Pyla Rao
Ranch Hand

Joined: Jul 10, 2012
Posts: 50
can you elaborate more or can you expose your source..??? Then i will surely help you..
Mark Butcher
Ranch Hand

Joined: Jun 28, 2012
Posts: 46
Sure, here is the code.

validation.xml :



validator-rules.xml :


JSP :


struts-config :


Eclipse error : The content of element type "field" must match "(msg|arg|var)*".

Login page error : java.lang.NullPointerException: Depends string "required" was not found in validator-rules.xml

Thanks
Mark

Shankar Tanikella
Ranch Hand

Joined: Jan 30, 2011
Posts: 329

Hi Mark,
Everything looks fine but for the validators "allrequired" and "required" are using the same method signature. Have you overwritten the validator code. In any case how come two different validators use same method from the same class using same attributes [non user defined] and perform different operations?

Looks like you have to remove "allrequired" validator from your validation-rules file if it is added by mistake.



Have Fun with Java
little,little.. little by little makes a lot..
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Struts 1.3 Validation Problem