# C1.WPF.FlexGrid.UndoStack

## Content

<div class="doc-site-dotnet-api-container">



  <h1 id="C1_WPF_FlexGrid_UndoStack" data-uid="C1.WPF.FlexGrid.UndoStack" class="text-break">UndoStack Class
</h1>
  <div class="markdown level0 summary"><p>Generic Undo/Redo stack.</p>
</div>
  <div class="markdown level0 conceptual"></div>
  <div class="inheritance">
    <h5>Inheritance</h5>
    <div class="level0"><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.object">object</a></div>
    <div class="level1"><span class="xref">UndoStack</span></div>
      <div class="level2"><a class="xref" href="C1.WPF.FlexGrid.ExcelUndoStack.html">ExcelUndoStack</a></div>
  </div>
  <h6><strong>Namespace</strong>: <a class="xref" href="C1.WPF.FlexGrid.html">C1.WPF.FlexGrid</a></h6>
  <h6><strong>Assembly</strong>: C1.WPF.FlexSheet.4.6.2.dll</h6>
  <h5 id="C1_WPF_FlexGrid_UndoStack_syntax">Syntax</h5>
  <div class="codewrapper">
    <pre><code class="lang-csharp hljs">public class UndoStack</code></pre>
  </div>
  <div class="codewrapper">
    <pre><code class="lang-vbnet hljs">Public Class UndoStack</code></pre>
  </div>
  <h3 id="constructors">Constructors
</h3>
  <table class="table table-bordered table-condensed">
    <thead>
      <tr>
        <th>Name</th>
        <th>Description</th>
      </tr>
    </thead>
    <tbody>
      <tr>
        <td id="C1_WPF_FlexGrid_UndoStack__ctor" data-uid="C1.WPF.FlexGrid.UndoStack.#ctor">
          <a class="xref" href="C1.WPF.FlexGrid.UndoStack.-ctor.html#C1_WPF_FlexGrid_UndoStack__ctor">UndoStack()</a>
        </td>
        <td class="markdown level1 summary"><p>Initializes a new instance of an <a class="xref" href="C1.WPF.FlexGrid.UndoStack.html">UndoStack</a>.</p>
</td>
      </tr>
    </tbody>
  </table>
  <h3 id="properties">Properties
</h3>
  <table class="table table-bordered table-condensed">
    <thead>
      <tr>
        <th>Name</th>
        <th>Description</th>
      </tr>
    </thead>
    <tbody>
      <tr>
        <td id="C1_WPF_FlexGrid_UndoStack_CanRedo" data-uid="C1.WPF.FlexGrid.UndoStack.CanRedo">
          <a class="xref" href="C1.WPF.FlexGrid.UndoStack.CanRedo.html#C1_WPF_FlexGrid_UndoStack_CanRedo">CanRedo</a>
        </td>
        <td class="markdown level1 summary"><p>Gets a value that indicates whether the stack contains actions that can be re-done.</p>
</td>
      </tr>
      <tr>
        <td id="C1_WPF_FlexGrid_UndoStack_CanUndo" data-uid="C1.WPF.FlexGrid.UndoStack.CanUndo">
          <a class="xref" href="C1.WPF.FlexGrid.UndoStack.CanUndo.html#C1_WPF_FlexGrid_UndoStack_CanUndo">CanUndo</a>
        </td>
        <td class="markdown level1 summary"><p>Gets a value that indicates whether the stack contains actions that can be undone.</p>
</td>
      </tr>
    </tbody>
  </table>
  <h3 id="methods">Methods
</h3>
  <table class="table table-bordered table-condensed">
    <thead>
      <tr>
        <th>Name</th>
        <th>Description</th>
      </tr>
    </thead>
    <tbody>
      <tr>
        <td id="C1_WPF_FlexGrid_UndoStack_AddAction_C1_WPF_FlexGrid_IUndoableAction_" data-uid="C1.WPF.FlexGrid.UndoStack.AddAction(C1.WPF.FlexGrid.IUndoableAction)">
          <a class="xref" href="C1.WPF.FlexGrid.UndoStack.AddAction.html#C1_WPF_FlexGrid_UndoStack_AddAction_C1_WPF_FlexGrid_IUndoableAction_">AddAction(IUndoableAction)</a>
        </td>
        <td class="markdown level1 summary"><p>Adds an action to the undo/redo stack.</p>
</td>
      </tr>
      <tr>
        <td id="C1_WPF_FlexGrid_UndoStack_Clear" data-uid="C1.WPF.FlexGrid.UndoStack.Clear">
          <a class="xref" href="C1.WPF.FlexGrid.UndoStack.Clear.html#C1_WPF_FlexGrid_UndoStack_Clear">Clear()</a>
        </td>
        <td class="markdown level1 summary"><p>Clears the undo/redo stack.</p>
</td>
      </tr>
      <tr>
        <td id="C1_WPF_FlexGrid_UndoStack_OnStateChanged_System_EventArgs_" data-uid="C1.WPF.FlexGrid.UndoStack.OnStateChanged(System.EventArgs)">
          <a class="xref" href="C1.WPF.FlexGrid.UndoStack.OnStateChanged.html#C1_WPF_FlexGrid_UndoStack_OnStateChanged_System_EventArgs_">OnStateChanged(EventArgs)</a>
        </td>
        <td class="markdown level1 summary"><p>Raises the <a class="xref" href="C1.WPF.FlexGrid.UndoStack.StateChanged.html">StateChanged</a> event.</p>
</td>
      </tr>
      <tr>
        <td id="C1_WPF_FlexGrid_UndoStack_Redo" data-uid="C1.WPF.FlexGrid.UndoStack.Redo">
          <a class="xref" href="C1.WPF.FlexGrid.UndoStack.Redo.html#C1_WPF_FlexGrid_UndoStack_Redo">Redo()</a>
        </td>
        <td class="markdown level1 summary"><p>Executes a Redo command.</p>
</td>
      </tr>
      <tr>
        <td id="C1_WPF_FlexGrid_UndoStack_Undo" data-uid="C1.WPF.FlexGrid.UndoStack.Undo">
          <a class="xref" href="C1.WPF.FlexGrid.UndoStack.Undo.html#C1_WPF_FlexGrid_UndoStack_Undo">Undo()</a>
        </td>
        <td class="markdown level1 summary"><p>Executes an Undo command.</p>
</td>
      </tr>
    </tbody>
  </table>
  <h3 id="events">Events
</h3>
  <table class="table table-bordered table-condensed">
    <thead>
      <tr>
        <th>Name</th>
        <th>Description</th>
      </tr>
    </thead>
    <tbody>
      <tr>
        <td id="C1_WPF_FlexGrid_UndoStack_StateChanged" data-uid="C1.WPF.FlexGrid.UndoStack.StateChanged">
          <a class="xref" href="C1.WPF.FlexGrid.UndoStack.StateChanged.html">StateChanged</a>
        </td>
        <td class="markdown level1 summary"><p>Occurs when the status of the undo stack changes.</p>
</td>
      </tr>
    </tbody>
  </table>

</div>
