DropDownList Question?

Results 1 to 2 of 2

Thread: DropDownList Question?

  1. #1
    Join Date
    Dec 1969

    Default DropDownList Question?

    I have a search link which, when clicked, repopulates fields in a tab. What I need to know is how do I use the value I pulled out of the database and populate a dropdown list box using the value from the database? <BR>So if I pull STATE out of the database, I want to use that value to find it in the DDL and set the focus on that value when populating the DDL. <BR>So If I have &#039;Georgia&#039; in the database, I want to set the DDL&#039;s focus on that value. This is specifically dealing with Web Controls.

  2. #2
    Join Date
    Dec 1969

    Default RE: DropDownList Question?

    Loop through the Items collection. When you find the option that you want to be set, set the SelectedIndex to be the value of the current loop iteration.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts