Creating listbox for Role and initially populating with loop
myDataTable = myDataSet.Table s(1)
lbRole.Items.Cl ear()
Dim dataRow_t As DataRow
For Each dataRow_t In myDataTable.Row s
lbRole.Items.Ad d(dataRow_t("Ro le_Desc"))
Next dataRow_t
lbRole.Selected Index = -1
Thought I would try using binding
lbRole.Items.Cl ear()
lbRole.DisplayM ember = "role_desc"
lbRole.ValueMem ber = "role_id"
lbRole.DataSour ce = myDataSet.Table s(1)
lbRole.Selected Index = -1
When I use looping method, I am able to set lbRole.Selected Index = -1
so no value is selected for the listbox. When I try the same method for
the binding, I still get a value selected.
I would like to bind, but need to be able allow input with no role
selected.
Thanks in advance...
myDataTable = myDataSet.Table s(1)
lbRole.Items.Cl ear()
Dim dataRow_t As DataRow
For Each dataRow_t In myDataTable.Row s
lbRole.Items.Ad d(dataRow_t("Ro le_Desc"))
Next dataRow_t
lbRole.Selected Index = -1
Thought I would try using binding
lbRole.Items.Cl ear()
lbRole.DisplayM ember = "role_desc"
lbRole.ValueMem ber = "role_id"
lbRole.DataSour ce = myDataSet.Table s(1)
lbRole.Selected Index = -1
When I use looping method, I am able to set lbRole.Selected Index = -1
so no value is selected for the listbox. When I try the same method for
the binding, I still get a value selected.
I would like to bind, but need to be able allow input with no role
selected.
Thanks in advance...
Comment