# GrapeCity.Spreadsheet.Commands.PivotTables.PivotTableOptionsCommand.BeforeExecute

## Content

<div class="doc-site-dotnet-api-container">



<h1 id="GrapeCity_Spreadsheet_Commands_PivotTables_PivotTableOptionsCommand_BeforeExecute_" data-uid="GrapeCity.Spreadsheet.Commands.PivotTables.PivotTableOptionsCommand.BeforeExecute*">BeforeExecute Method
</h1>
<div class="markdown level0 summary"></div>
<div class="markdown level0 conceptual"></div>



<a id="GrapeCity_Spreadsheet_Commands_PivotTables_PivotTableOptionsCommand_BeforeExecute_" data-uid="GrapeCity.Spreadsheet.Commands.PivotTables.PivotTableOptionsCommand.BeforeExecute*"></a>
<h4 id="GrapeCity_Spreadsheet_Commands_PivotTables_PivotTableOptionsCommand_BeforeExecute_System_Boolean_" data-uid="GrapeCity.Spreadsheet.Commands.PivotTables.PivotTableOptionsCommand.BeforeExecute(System.Boolean)">BeforeExecute(bool)</h4>
<div class="markdown level1 summary"><p>Invoked before execute the command.</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="declaration">Declaration</h5>
<div class="codewrapper">
  <pre><code class="lang-csharp hljs">protected override CommandResult BeforeExecute(bool redo)</code></pre>
</div>
<div class="codewrapper">
  <pre><code class="lang-vbnet hljs">Protected Overrides Function BeforeExecute(redo As Boolean) As CommandResult</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-condensed">
  <thead>
    <tr>
      <th>Type</th>
      <th>Name</th>
      <th>Description</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.boolean">bool</a></td>
      <td><span class="parametername">redo</span></td>
      <td><p>if set to <code>true</code>, the command is executed for redoing.</p>
</td>
    </tr>
  </tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-condensed">
  <thead>
    <tr>
      <th>Type</th>
      <th>Description</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td><span class="xref">CommandResult</span></td>
      <td><p><code>true</code> if the command continue executing; otherwise the command should be stopped.</p>
</td>
    </tr>
  </tbody>
</table>
<h5 class="overrides">Overrides</h5>
<div><a class="xref" href="GrapeCity.Spreadsheet.Commands.Command.BeforeExecute.html#GrapeCity_Spreadsheet_Commands_Command_BeforeExecute_System_Boolean_">Command.BeforeExecute(bool)</a></div>
</div>
