I have a long ListView which contains a list of actions which my app is currently running (each action at a time). Upon running each action, the relevant ListViewItem is bolded. The ListView is long so I have vertical scroll bar.
My question is how to make the current running action shown to the user, meaning, how do I "scroll" the list view to that item.
I tried to manually select the row ==> didn't work. I've used ListViewItem.EnsureVisible but that made the ListView flicker on each change.
Any idea? Thanks.
Edited: I've added some code, even though the code is pretty simple. Whenever a new action is running, I run the following:
foreach (ListViewItem item in m_ListView.Items)
{
FontStyle style = ((index == value) ? FontStyle.Bold : FontStyle.Regular);
item.Font = new Font(item.Font, style);
if (index == value)
{
m_ModulesListView.EnsureVisible(index);
}
index++;
}