Just create a Collection (here gender of the Databaseentries (f,m) and pass as a bean to the page
with the form.
<html:select name="yourForm" property="gender">
<html:options collection="gender" property="id" labelProperty="description"/>
</html:select>
If you need more assistance have a look at :
http://www.reumann.net/do/struts/lesson3
Regards, Thomas
On Thu, 4 Sep 2003 02:38:16 -0700 (PDT), Goldy J <[EMAIL PROTECTED]> wrote:
Hello,
I have a JSP in which there are number of dropdown along with text boxes. I am using struts tag lib for getting the value when I submit the form.
The problem is when I try to populate the dropdown in th JSP with the data that i get from the databse .
For example I have dropdown for gender with option M,F.Now when I select and submit it I am OK but when I query and get the value from DB It doesnt set to appropiate value but always with the deafult M. same for others dropdowns.
Iam using the following in my JSP
<html:select property ="gender"><htrml:option value="m"></html:option><htrml:option value="f"></html:option></html:select>
In formbean String gender; setGender{}; getGender{};
Any help will be highly appreciated Thanks in advance.
--------------------------------- Do you Yahoo!? Yahoo! SiteBuilder - Free, easy-to-use web site design software
-- Using M2, Opera's revolutionary e-mail client: http://www.opera.com/m2/
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]

