Author: mexican | Posted on: 10/15/2008 2:25:18 AM | Views : 349

I have a dropdownlist and want to assign it the selected value of whatever i get from a database field.

I dont want to add a new enter as all entries in DDL are already entered.
I can retrieve the value and also i used findByIndex without success.


 Label1.Text = ds.Tables(0).Rows(0).Item(3) 'correct output
       DropDownList2.SelectedValue = ds.Tables(0).Rows(0).Item(3).ToString() 'object not set error?

...

Go to the complete details ...