dcsimg
2 Select boxes, one loads dynamically
1 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   Poorav_Chaudhari
Posted On:   Thursday, January 31, 2002 12:04 PM

For my application, I have two select boxes. When a user makes a change in the first select box, i do a query search and reload the page with the second select box with corresponding values. I use the LabelValuebean to populate the second select box since i need to different values for label and value! Now here is my problem. when a user clicks on submit, i do a validation check. If invalid I want to bring the user back to the page, but when i do my second select box goes blank. The value for that field in that form is not restored. I know that the form names I have used are correct. The second select box is not loaded from a form tag. but is created in the action servlet and sent to the page using the request.Attribute clause. please let me know what    More>>

For my application, I have two select boxes. When a user makes a change in the first select box, i do a query search and reload the page with the second select box with corresponding values. I use the LabelValuebean to populate the second select box since i need to different values for label and value! Now here is my problem. when a user clicks on submit, i do a validation check. If invalid I want to bring the user back to the page, but when i do my second select box goes blank. The value for that field in that form is not restored. I know that the form names I have used are correct. The second select box is not loaded from a form tag. but is created in the action servlet and sent to the page using the request.Attribute clause.

please let me know what i am doing wrong.

all help is appreciated. thank you
poorav

   <<Less

Re: 2 Select boxes, one loads dynamically

Posted By:   Jason_Rosenblum  
Posted On:   Thursday, January 31, 2002 04:45 PM

let me ask you a couple of questions:
1) are you using tags?
2) are you using the validate() method in ActionForm?
3) where do you populate your dropdowns? in the Action servlet?
About | Sitemap | Contact