Win a copy of The Java Performance Companion this week in the Performance forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

saving hidden fields in Action Forms

 
AnilPrakash Raju
Ranch Hand
Posts: 137
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

In my jsp page I got some hidden fields in a form with some input fields.

When i submit this page it goes to the an ActionForm to validate the input fields.

If there are some errors found, it goes back to the jsp pages but i lose the values of the hidden fields.

is there any way of getting back the values of the hidden fields when there are errors present?

It works ok if there are no errors presents.

Thanks in advance

Anil
 
Leandro Melo
Ranch Hand
Posts: 401
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Are the hidden fields declared in the form bean?
If not, try declaring in struts-config.xml and in the associated ActionForm.
 
AnilPrakash Raju
Ranch Hand
Posts: 137
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

The hidden fields are declared in the bean and when i step throught the actionForm I can see the values. But the values is not displayed if some errors are found.

thanks

Anil
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic