C# Prevent ItemChecked event on a ListView from Interering with SubItemClicked?
Posted
by John M
on Stack Overflow
See other posts from Stack Overflow
or by John M
Published on 2010-06-17T20:00:27Z
Indexed on
2010/06/17
20:03 UTC
Read the original article
Hit count: 783
I am using a in-place editable listview control for a project.
The editable listview adds a 'SubItemClicked' event so that each 'cell' can be edited.
lstSD2.SubItemClicked += new ListViewEx.SubItemEventHandler(lstSD2_SubItemClicked);
I also have the listview checkboxes enabled with a 'ItemChecked' event.
The problem is that once the 'ItemChecked' event is enabled double-clicking on any row fires the 'ItemChecked' event and prevents the 'SubItemClicked' event from firing.
Is there a way to enforce the need to actually 'check' the listview checkbox instead of firing whenever the row is double-clicked?
© Stack Overflow or respective owner