It's not a secret anymore!
The moose likes Struts and the fly likes retaining values Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "retaining values" Watch "retaining values" New topic

retaining values

venkatesh warlu
Ranch Hand

Joined: Mar 11, 2008
Posts: 33
Hi all,

I have two tabs in my page with lots of drop down boxes in it. if i change the values within one tabs drop down and go to other tab and come back and see then the value which i have selected gets set to default value which on load i am setting it. How do i retain the values.

I am using struts.

Is there any way of doing it with hidden fields or some other trick , if so please help me with a sample code. thanks in advance ranchers.


Surya Kant
Ranch Hand

Joined: Mar 29, 2005
Posts: 104
Well,It depends on how you want to go about it.
You can store them in session
You store the values as hidden variables
Or you can use form beans for this purpose
I agree. Here's the link:
subject: retaining values
It's not a secret anymore!