Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

struts validation for two months and years

 
harsha addala
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have problem with validations using struts. My application contains two text boxes of years and months and i require to validate them using validator.xml. The problem is , whenever i am validating the two text boxes, two error messages are displaying but i require to display only one error message for both the fields. Can anyone help me regarding this issue.
if possible post the required code.
 
Ernest Friedman-Hill
author and iconoclast
Marshal
Pie
Posts: 24212
35
Chrome Eclipse IDE Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
We have a whole forum devoted to Struts, further down the front page of the Saloon; I will move this there for you.
 
Merrill Higginson
Ranch Hand
Posts: 4864
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'm afraid this isn't possible with the "out of the box" validators provided by Struts and the Apache validation framework. You will have to create a custom validation rule. See the heading "Pluggable Validators" in this link for more information on how to do that.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic