Dropdown list box

Results 1 to 2 of 2

Thread: Dropdown list box

  1. #1
    Join Date
    Dec 1969

    Default Dropdown list box

    I created a dropdown list box that is filled from a SQL Server 2000 database. I used the dataAdapter dataConnection and dataSet to fill the Dropdown. The only thing is the first value is shown on the dropdow when I view the code on the browser, does anyone know how to make the dropdown text blank until the user select the dropdown to see the selection. thankyou for your time.

  2. #2
    Join Date
    Dec 1969

    Default RE: Dropdown list box

    In your subroutine, after you call the databind method, do this:<BR>dropListName.Items.Insert(0, New ListItem( "Select", -1))<BR><BR>To check that something has been selected you could do something like this:<BR>mySelection = dropListName.SelectedItem.Value<BR>If mySelection &#060;&#062; -1 Then<BR>&#039;whatever<BR>End If

Posting Permissions

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