c# - Bound ListBox SelectedIndex keeps changing -


i have listbox bound list. every-time listbox updates reflect collection, selectedindex changes top item. how can stop behavior , retain current selectedindex?

[update]

i found better collection use kind of functionality - 'bindinglist': http://msdn.microsoft.com/en-us/library/ms132679(v=vs.90).aspx.

wulfgarpro.

when [...] updates reflect collection

does mean there new collection? if "the same position" mean?

when re-binding a(nother) list, have save & restore index position. write code around place update datasource.


Comments

Popular posts from this blog

java - SNMP4J General Variable Binding Error -

windows - Python Service Installation - "Could not find PythonClass entry" -

Determine if a XmlNode is empty or null in C#? -