A friendly place for programming greenhorns!
Big Moose Saloon
Register / Login
Joined: May 18, 2005
May 18, 2005 01:55:00
Iam trying to repopulate form fields. I get the data from a database and populate the form bean. I want to update this data, so i need to place them in the fields.
where would i put it in the
is it in this tag ???
if so what is the correct syntax for calling the field
Joined: Apr 14, 2005
May 18, 2005 08:01:00
inside your Action.execute(), do form.set("formFieldName", databaseValue); where 'form' is the local variable refering to the ActionForm to which the action is mapped.
also, you'll want to use the struts-html library to build your form, NOT the old HTML form tags.
-/a<br />certified slacker...yes, my last name is 'do' - <a href="http://www.luckycouple.com" target="_blank" rel="nofollow">luckycouple.com</a>
I agree. Here's the link:
Data across multiple actions
problem with multipart/form-data
Display data from database to jsp page.
deploy the bean
All times are in JavaRanch time: GMT-6 in summer, GMT-7 in winter
| Powered by
Copyright © 1998-2014