Setting values in an asp:dropdownlist

  • Thread starter Thread starter Kerri
  • Start date Start date
K

Kerri

I have a page that allows users to create a user account.

The aspx has various dropdowns that I populate by binding
the dropdownlist to a dataset.

OK so far?

However, I also want a page where the user can edit their
profile..so I need to be able to set the selected value
based on what is saved in my user table and I also need
to add the extra entries.

Anyone know how I can do this easily.

Do I need to join on my user table and my table that has
all the various categories in order to get the selected
value and add my other values??


Thanks,
Kerri.
 
Hi,

after the databinding you can use MyDropDownList.SelectedValue to set it to
correct value for a particular user.

Best regards,

Marc Höppner
NeoGeo
 
Back
Top