---
title: "ListItem..::.StateChanging Event"
canonical: https://www.graphicsmill.com/docs/gm5/E_Aurigma_GraphicsMill_WinControls_ListItem_StateChanging.htm
product: "Graphics Mill 5.5 for .NET"
---

This documentation is for the old version. [Go to the latest Graphics Mill docs](https://www.graphicsmill.com/docs/gm/)

# ListItem.StateChanging Event
 
Fires when the item state is about to be changed.
 
**Namespace:** [Aurigma.GraphicsMill.WinControls](https://www.graphicsmill.com/docs/gm5/N_Aurigma_GraphicsMill_WinControls.htm.md)
 **Assembly:** Aurigma.GraphicsMill.WinControls (in Aurigma.GraphicsMill.WinControls.dll)
 
## Syntax
  
```
Public Event StateChanging As StateChangingEventHandler
```
 
```csharp
public event StateChangingEventHandler StateChanging
```
 
### Implements
 
[IListItem.StateChanging](https://www.graphicsmill.com/docs/gm5/E_Aurigma_GraphicsMill_WinControls_IListItem_StateChanging.htm.md)
 
## Remarks
  
Item state is defined by several properties: [Checked](https://www.graphicsmill.com/docs/gm5/P_Aurigma_GraphicsMill_WinControls_IListItem_Checked.htm.md), [Focused](https://www.graphicsmill.com/docs/gm5/P_Aurigma_GraphicsMill_WinControls_IListItem_Focused.htm.md), and [Selected](https://www.graphicsmill.com/docs/gm5/P_Aurigma_GraphicsMill_WinControls_IListItem_Selected.htm.md). This event is raised whenever some of these properties are about to be modified.
 
Main intent of this property is a possibility to disallow changing an item state. For example, if you do not want to allow the user to check some items (e.g. if they are too large), you should handle this event and set the [Cancel](https://www.graphicsmill.com/docs/gm5/P_Aurigma_GraphicsMill_WinControls_StateChangingEventArgs_Cancel.htm.md) argument to **true** for those items.
   
## See Also

### Reference

- [ListItem Class](https://www.graphicsmill.com/docs/gm5/T_Aurigma_GraphicsMill_WinControls_ListItem.htm.md)
- [Aurigma.GraphicsMill.WinControls Namespace](https://www.graphicsmill.com/docs/gm5/N_Aurigma_GraphicsMill_WinControls.htm.md)
