ItemCheckEventArgs Class
Provides data for the ItemCheck event of the CheckedListBox and ListView controls.
Assembly: System.Windows.Forms (in System.Windows.Forms.dll)
| Name | Description | |
|---|---|---|
![]() | ItemCheckEventArgs(Int32, CheckState, CheckState) | Initializes a new instance of the ItemCheckEventArgs class. |
| Name | Description | |
|---|---|---|
![]() | CurrentValue | Gets a value indicating the current state of the item's check box. |
![]() | Index | Gets the zero-based index of the item to change. |
![]() | NewValue | Gets or sets a value indicating whether to set the check box for the item to be checked, unchecked, or indeterminate. |
| Name | Description | |
|---|---|---|
![]() | Equals(Object) | Determines whether the specified object is equal to the current object.(Inherited from Object.) |
![]() | Finalize() | Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.(Inherited from Object.) |
![]() | GetHashCode() | Serves as the default hash function. (Inherited from Object.) |
![]() | GetType() | |
![]() | MemberwiseClone() | |
![]() | ToString() | Returns a string that represents the current object.(Inherited from Object.) |
The ItemCheck event occurs when the checked state of an item in a checked list box changes. The ItemCheckEventArgs class specifies the index of the item to change, the current value of the check box for the item, and the new value to set for the check box.
For more information about handling events, see Handling and Raising Events.
The following code example demonstrates a checked ListView control that handles the ListView.ItemCheck event. The method uses the CurrentValue and Index properties of the ItemCheckEventArgs object to retrieve and tally the price of the menu items selected. To run this example paste the following code in a form containing a ListView named ListView1 and a TextBox named Textbox1. Call the InititalizeListView method from the form's constructor or Load method. Ensure all events are associated with their event-handling methods.
Available since 1.1
Any public static ( Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.


