dcsimg
Generating Dynamic Forms using Struts
1 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   Hemant_Sharma
Posted On:   Wednesday, January 22, 2003 02:58 PM

Hi, I have a problem with struts. The situation is like this:
I have a JSP page and on this page submition I want to open a data entry form which will contain fields based on the data entered on first page. These fields i want to get from database. The question is where i need to put the code to get these fields? In my Form, Action class or In my JSP???
If some body can give sample code it will be helpful.
Thanks

Re: Generating Dynamic Forms using Struts

Posted By:   mark_lowe  
Posted On:   Thursday, January 23, 2003 07:17 AM

i had the same problem getting a straight answer on this...

Okay.. First go to www.keyboardmonkey.com .. Do the nested beans tutorial...

This shows you the basics of dynamic form generation using struts.. You can also reference nested beans in version 1 struts tags, which the tutorial also explains.. The tutorial takes less than an hour and nested beans according to me is the only proper way (proper = mvc) of form generation..

All i can say is you don't need scriptlets and don't listen to anyone suggesting such nonesense... The struts docs and web sources are pretty sparse on this subject, which is a suprise because its the coolest thing about the whole thing.

hope this helps....
About | Sitemap | Contact