panza
May 27th, 1999, 04:43 AM
Hey,
I'm using these lines to scroll & highlight to a specific item in my list... it *scrolls*,
but the line is not being selected/focues/highlighted. All examples from the
"selection"-part from the listview control topic here at codeguru don't work
either...
(I have set LVM_SETEXTENDEDLISTVIEWSTYLE & LVS_EX_FULLROWSELECT
before and it works great when clicking into the view)
m_liste.EnsureVisible( pos, NULL);
m_liste.SetItemState( pos, LVIS_SELECTED, LVIS_SELECTED);
m_liste.Update( pos);
I tried these other SetItemState-Calls - they all don't work (they all return a nonzero-value, so they
SEEM to do something, but nothing actually happens):
m_liste.SetItemState( pos, LVIS_SELECTED | LVIS_FOCUSED, LVIF_STATE);
m_liste.SetItemState( pos, LVIS_SELECTED | LVIS_FOCUSED, LVIS_SELECTED | LVIS_FOCUSED);
m_liste.SetItemState( pos, LVIS_SELECTED, LVIF_STATE);
Any idea, anyone?
Thank you.
-.-.-
I'm using these lines to scroll & highlight to a specific item in my list... it *scrolls*,
but the line is not being selected/focues/highlighted. All examples from the
"selection"-part from the listview control topic here at codeguru don't work
either...
(I have set LVM_SETEXTENDEDLISTVIEWSTYLE & LVS_EX_FULLROWSELECT
before and it works great when clicking into the view)
m_liste.EnsureVisible( pos, NULL);
m_liste.SetItemState( pos, LVIS_SELECTED, LVIS_SELECTED);
m_liste.Update( pos);
I tried these other SetItemState-Calls - they all don't work (they all return a nonzero-value, so they
SEEM to do something, but nothing actually happens):
m_liste.SetItemState( pos, LVIS_SELECTED | LVIS_FOCUSED, LVIF_STATE);
m_liste.SetItemState( pos, LVIS_SELECTED | LVIS_FOCUSED, LVIS_SELECTED | LVIS_FOCUSED);
m_liste.SetItemState( pos, LVIS_SELECTED, LVIF_STATE);
Any idea, anyone?
Thank you.
-.-.-