gchq
Well-known member
- Joined
- Dec 14, 2007
- Messages
- 168
- Programming Experience
- 10+
Hi there
I have a function that changes the text in the DisplayMember of a ListBox by first changing the DataTable DataSource and then reloading the datasource.
Trouble is, editing any value under the first item causes the DisplayMember values to 'vanish' from sight - they are still there as you can click on them, they just can't be viewed!
Any idea what might be happening?
I have a function that changes the text in the DisplayMember of a ListBox by first changing the DataTable DataSource and then reloading the datasource.
Trouble is, editing any value under the first item causes the DisplayMember values to 'vanish' from sight - they are still there as you can click on them, they just can't be viewed!
Any idea what might be happening?
VB.NET:
RevenueDT.Select("ID = " & SelectedDTID)(0)("Name") = NewValue
With RevenueListBox
.DataSource = Nothing
.DataSource = RevenueDT
.DisplayMember = "Name"
.ValueMember = "ID"
.SelectedIndex = SelectedDTIndex
End With