Google Website Translator Gadget

domingo, 21 de octubre de 2012

Struts2: tag.getValidators("${tagName}") error

During the execution (and if you have the debug mode activate) you are getting an error similar to:


----------
==> list tag.getValidators("${tagName}") as validator [on line 46, column 9 in template/xhtml/form-close-validate.ftl]
in include "/${parameters.templateDir}/xhtml/form-close-validate.ftl" [on line 25, column 1 in template/xhtml/form-close.ftl]
----------
...several lines...
Caused by: java.lang.NullPointerException
......
I've tried to found the real cause unsucessfully but finally I've follow the next steps to solve the issue:
The -validation.xml file is with the .java class 
s
The message in the -validation.xml file is properly set ${getText("800_u01ra_error_001")}
My solution has been:
remove validate="true" from the form
s:form action="Peticio01pas1"
 method="post" name="selectfile">

For complete information about struts2 validation you could visit the following link:
http://struts.apache.org/2.3.4.1/docs/validation.html

No hay comentarios:

Publicar un comentario