# FarPoint.Win.Spread.FpSpread.AddNewSheetView

## Content

<div class="doc-site-dotnet-api-container">



<h1 id="FarPoint_Win_Spread_FpSpread_AddNewSheetView_" data-uid="FarPoint.Win.Spread.FpSpread.AddNewSheetView*">AddNewSheetView Method
</h1>
<div class="markdown level0 summary"></div>
<div class="markdown level0 conceptual"></div>



<a id="FarPoint_Win_Spread_FpSpread_AddNewSheetView_" data-uid="FarPoint.Win.Spread.FpSpread.AddNewSheetView*"></a>
<h4 id="FarPoint_Win_Spread_FpSpread_AddNewSheetView_System_Int32_System_String_System_Int32_System_Int32_System_Boolean_System_Boolean_" data-uid="FarPoint.Win.Spread.FpSpread.AddNewSheetView(System.Int32,System.String,System.Int32,System.Int32,System.Boolean,System.Boolean)">AddNewSheetView(int, string, int, int, bool, bool)</h4>
<div class="markdown level1 summary"><p>Creates a new SheetView and inserts or replaces the sheet at the specified sheet index.</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="declaration">Declaration</h5>
<div class="codewrapper">
  <pre><code class="lang-csharp hljs">public SheetView AddNewSheetView(int sheetIndex = -1, string sheetName = null, int rowCount = -1, int columnCount = -1, bool shareNamedStyle = true, bool replace = false)</code></pre>
</div>
<div class="codewrapper">
  <pre><code class="lang-vbnet hljs">Public Function AddNewSheetView(Optional sheetIndex As Integer = -1, Optional sheetName As String = Nothing, Optional rowCount As Integer = -1, Optional columnCount As Integer = -1, Optional shareNamedStyle As Boolean = True, Optional replace As Boolean = False) As SheetView</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.int32">int</a></td>
      <td><span class="parametername">sheetIndex</span></td>
      <td><p>The sheet index is where the new SheetView is inserted or replaced.
If sheetIndex is -1, the new SheetView is added to the end of SheetViewCollection.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.string">string</a></td>
      <td><span class="parametername">sheetName</span></td>
      <td><p>The sheet name.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.int32">int</a></td>
      <td><span class="parametername">rowCount</span></td>
      <td><p>Row count of the new sheet. -1 for default count.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.int32">int</a></td>
      <td><span class="parametername">columnCount</span></td>
      <td><p>Column count of the new sheet. -1 for default count.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.boolean">bool</a></td>
      <td><span class="parametername">shareNamedStyle</span></td>
      <td><p>Indicates whether the new SheetView shares the named style of Spread</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.boolean">bool</a></td>
      <td><span class="parametername">replace</span></td>
      <td><p>Indicates whether the new SheetView replaces the current sheet at the specified sheet index</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><a class="xref" href="FarPoint.Win.Spread.SheetView.html">SheetView</a></td>
      <td><p>A new SheetView</p>
</td>
    </tr>
  </tbody>
</table>
</div>
