---
title: "Bitmap..::.UndoRedoEnabled Property "
canonical: https://www.graphicsmill.com/docs/gm5/P_Aurigma_GraphicsMill_Bitmap_UndoRedoEnabled.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/)

# Bitmap.UndoRedoEnabled Property 
 
Enables or disables undo/redo functionality.
 
**Namespace:** [Aurigma.GraphicsMill](https://www.graphicsmill.com/docs/gm5/N_Aurigma_GraphicsMill.htm.md)
 **Assembly:** Aurigma.GraphicsMill (in Aurigma.GraphicsMill.dll)
 
## Syntax
  
```
Public Overridable Property UndoRedoEnabled As Boolean
```
 
```csharp
public virtual bool UndoRedoEnabled { get; set; }
```
 
### Property Value
Value specifying if to enable undo/redo functionality.
 
### Implements
 
[IStateNavigable.UndoRedoEnabled](https://www.graphicsmill.com/docs/gm5/P_Aurigma_GraphicsMill_IStateNavigable_UndoRedoEnabled.htm.md)
 
## Remarks
  
You can use this property to disable undo/redo functionality for some time. It is useful when, for example, you apply some set of effects or draw a number of shapes as single atomic operation. In this case you likely do not want to undo sub-operations, but need to undo entire operation at once. For example, you draw a star (with several calls of [DrawLine(Pen, Int32, Int32, Int32, Int32)](https://www.graphicsmill.com/docs/gm5/M_Aurigma_GraphicsMill_Drawing_GdiGraphics_DrawLine_5_943d79c1.htm.md) method). Your actions should be the following:
 
1. Set this property to **false**.
2. Draw a star by attaching this [Bitmap](https://www.graphicsmill.com/docs/gm5/T_Aurigma_GraphicsMill_Bitmap.htm.md) to [GdiGraphics](https://www.graphicsmill.com/docs/gm5/T_Aurigma_GraphicsMill_Drawing_GdiGraphics.htm.md). Draw attention, although event [Changed](https://www.graphicsmill.com/docs/gm5/E_Aurigma_GraphicsMill_Bitmap_Changed.htm.md) fires, bitmap state is not stored.
3. After you finish, set this property back to **true**.
4. Save the result state with [SaveState()](https://www.graphicsmill.com/docs/gm5/M_Aurigma_GraphicsMill_Bitmap_SaveState.htm.md) method.

After this you can call [Undo()](https://www.graphicsmill.com/docs/gm5/M_Aurigma_GraphicsMill_Bitmap_Undo.htm.md) method and entire star is erased instead of single line you draw last time.
 
By default this property is **true**.
   
## See Also

### Reference

- [Bitmap Class](https://www.graphicsmill.com/docs/gm5/T_Aurigma_GraphicsMill_Bitmap.htm.md)
- [Aurigma.GraphicsMill Namespace](https://www.graphicsmill.com/docs/gm5/N_Aurigma_GraphicsMill.htm.md)
