Why can't I select any items from my DropDownList(info_cmpycde)?
Private Sub info_cmpycde_SelectedIndexChanged
cmpy.text = info_cmpycde.SelectedItem.Value
or
cmpy.text = info_cmpycde.SelectedItem.Text
End Sub
*cmpy textbox is still null value
Printable View
Why can't I select any items from my DropDownList(info_cmpycde)?
Private Sub info_cmpycde_SelectedIndexChanged
cmpy.text = info_cmpycde.SelectedItem.Value
or
cmpy.text = info_cmpycde.SelectedItem.Text
End Sub
*cmpy textbox is still null value
your sub needs to be
if you want the textbox to be updated as soon as you click the drop down list you will also need to set the autopostback=true property of the drop down listVB Code:
Private Sub info_cmpycde_SelectedIndexChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles info_cmpycde.SelectedIndexChanged cmpy.Text = info_cmpycde.SelectedItem.Value End Sub