I need to know how to insert a data reader object into a drop down box...I am missing something..
Here is what I have aleady..
Dim dr As SqlDataReader = SQL_Data.GetEmps1()
dr.Read()
If dr.HasRows() Then
DropDownList1.DataTextField = dr("Written_Name")
DropDownList1.DataValueField = dr("Employee_ID")
DropDownList1.DataBind()
End If
'Set's the Default Value to Add a User on a Drop Down Box.
DropDownList1.Items.Insert(0, AddaUser)
DropDownList1.SelectedIndex = 0
CheckBox1.Enabled = False
Here is what I have aleady..
Dim dr As SqlDataReader = SQL_Data.GetEmps1()
dr.Read()
If dr.HasRows() Then
DropDownList1.DataTextField = dr("Written_Name")
DropDownList1.DataValueField = dr("Employee_ID")
DropDownList1.DataBind()
End If
'Set's the Default Value to Add a User on a Drop Down Box.
DropDownList1.Items.Insert(0, AddaUser)
DropDownList1.SelectedIndex = 0
CheckBox1.Enabled = False