# C1.WPF.Excel.XLCellRange.-ctor

## Content

<div class="doc-site-dotnet-api-container">



<h1 id="C1_WPF_Excel_XLCellRange__ctor_" data-uid="C1.WPF.Excel.XLCellRange.#ctor*">XLCellRange Constructor
</h1>
<div class="markdown level0 summary"></div>
<div class="markdown level0 conceptual"></div>



<a id="C1_WPF_Excel_XLCellRange__ctor_" data-uid="C1.WPF.Excel.XLCellRange.#ctor*"></a>
<h4 id="C1_WPF_Excel_XLCellRange__ctor" data-uid="C1.WPF.Excel.XLCellRange.#ctor">XLCellRange()</h4>
<div class="markdown level1 summary"><p>Creates an instance of an <a class="xref" href="C1.WPF.Excel.XLCellRange.html">XLCellRange</a> object containing
an empty range.</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="declaration">Declaration</h5>
<div class="codewrapper">
  <pre><code class="lang-csharp hljs">public XLCellRange()</code></pre>
</div>
<div class="codewrapper">
  <pre><code class="lang-vbnet hljs">Public Sub New()</code></pre>
</div>


<a id="C1_WPF_Excel_XLCellRange__ctor_" data-uid="C1.WPF.Excel.XLCellRange.#ctor*"></a>
<h4 id="C1_WPF_Excel_XLCellRange__ctor_System_Int32_System_Int32_System_Int32_System_Int32_" data-uid="C1.WPF.Excel.XLCellRange.#ctor(System.Int32,System.Int32,System.Int32,System.Int32)">XLCellRange(int, int, int, int)</h4>
<div class="markdown level1 summary"><p>Creates an instance of an <a class="xref" href="C1.WPF.Excel.XLCellRange.html">XLCellRange</a> object containing a specified range.</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="declaration">Declaration</h5>
<div class="codewrapper">
  <pre><code class="lang-csharp hljs">public XLCellRange(int rowFrom, int rowTo, int colFrom, int colTo)</code></pre>
</div>
<div class="codewrapper">
  <pre><code class="lang-vbnet hljs">Public Sub New(rowFrom As Integer, rowTo As Integer, colFrom As Integer, colTo As Integer)</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">rowFrom</span></td>
      <td><p>Top row in the range.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.int32">int</a></td>
      <td><span class="parametername">rowTo</span></td>
      <td><p>Bottom row in the range.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.int32">int</a></td>
      <td><span class="parametername">colFrom</span></td>
      <td><p>Left column in the range.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.int32">int</a></td>
      <td><span class="parametername">colTo</span></td>
      <td><p>Right column in the range.</p>
</td>
    </tr>
  </tbody>
</table>


<a id="C1_WPF_Excel_XLCellRange__ctor_" data-uid="C1.WPF.Excel.XLCellRange.#ctor*"></a>
<h4 id="C1_WPF_Excel_XLCellRange__ctor_C1_WPF_Excel_XLSheet_System_Int32_System_Int32_System_Int32_System_Int32_" data-uid="C1.WPF.Excel.XLCellRange.#ctor(C1.WPF.Excel.XLSheet,System.Int32,System.Int32,System.Int32,System.Int32)">XLCellRange(XLSheet, int, int, int, int)</h4>
<div class="markdown level1 summary"><p>Creates an instance of an <a class="xref" href="C1.WPF.Excel.XLCellRange.html">XLCellRange</a> object containing a specified range.</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="declaration">Declaration</h5>
<div class="codewrapper">
  <pre><code class="lang-csharp hljs">public XLCellRange(XLSheet sheet, int rowFrom, int rowTo, int colFrom, int colTo)</code></pre>
</div>
<div class="codewrapper">
  <pre><code class="lang-vbnet hljs">Public Sub New(sheet As XLSheet, rowFrom As Integer, rowTo As Integer, colFrom As Integer, colTo As Integer)</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="C1.WPF.Excel.XLSheet.html">XLSheet</a></td>
      <td><span class="parametername">sheet</span></td>
      <td><p>The <a class="xref" href="C1.WPF.Excel.XLSheet.html">XLSheet</a> of this cell range.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.int32">int</a></td>
      <td><span class="parametername">rowFrom</span></td>
      <td><p>Top row in the range.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.int32">int</a></td>
      <td><span class="parametername">rowTo</span></td>
      <td><p>Bottom row in the range.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.int32">int</a></td>
      <td><span class="parametername">colFrom</span></td>
      <td><p>Left column in the range.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.int32">int</a></td>
      <td><span class="parametername">colTo</span></td>
      <td><p>Right column in the range.</p>
</td>
    </tr>
  </tbody>
</table>


<a id="C1_WPF_Excel_XLCellRange__ctor_" data-uid="C1.WPF.Excel.XLCellRange.#ctor*"></a>
<h4 id="C1_WPF_Excel_XLCellRange__ctor_C1_WPF_Excel_XLSheet_System_Int32_System_Int32_System_Int32_System_Int32_C1_WPF_Excel_XLReferenceType_C1_WPF_Excel_XLReferenceType_C1_WPF_Excel_XLReferenceType_C1_WPF_Excel_XLReferenceType_" data-uid="C1.WPF.Excel.XLCellRange.#ctor(C1.WPF.Excel.XLSheet,System.Int32,System.Int32,System.Int32,System.Int32,C1.WPF.Excel.XLReferenceType,C1.WPF.Excel.XLReferenceType,C1.WPF.Excel.XLReferenceType,C1.WPF.Excel.XLReferenceType)">XLCellRange(XLSheet, int, int, int, int, XLReferenceType, XLReferenceType, XLReferenceType, XLReferenceType)</h4>
<div class="markdown level1 summary"><p>Creates an instance of an <a class="xref" href="C1.WPF.Excel.XLCellRange.html">XLCellRange</a> object containing a specified range.</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="declaration">Declaration</h5>
<div class="codewrapper">
  <pre><code class="lang-csharp hljs">public XLCellRange(XLSheet sheet, int rowFrom, int rowTo, int colFrom, int colTo, XLReferenceType rowFromRef, XLReferenceType rowToRef, XLReferenceType colFromRef, XLReferenceType colToRef)</code></pre>
</div>
<div class="codewrapper">
  <pre><code class="lang-vbnet hljs">Public Sub New(sheet As XLSheet, rowFrom As Integer, rowTo As Integer, colFrom As Integer, colTo As Integer, rowFromRef As XLReferenceType, rowToRef As XLReferenceType, colFromRef As XLReferenceType, colToRef As XLReferenceType)</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="C1.WPF.Excel.XLSheet.html">XLSheet</a></td>
      <td><span class="parametername">sheet</span></td>
      <td><p>The <a class="xref" href="C1.WPF.Excel.XLSheet.html">XLSheet</a> of this cell range.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.int32">int</a></td>
      <td><span class="parametername">rowFrom</span></td>
      <td><p>T0op row in the range.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.int32">int</a></td>
      <td><span class="parametername">rowTo</span></td>
      <td><p>Bottom row in the range.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.int32">int</a></td>
      <td><span class="parametername">colFrom</span></td>
      <td><p>Left column in the range.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.int32">int</a></td>
      <td><span class="parametername">colTo</span></td>
      <td><p>Right column in the range.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="C1.WPF.Excel.XLReferenceType.html">XLReferenceType</a></td>
      <td><span class="parametername">rowFromRef</span></td>
      <td><p>The reference type of the top row in the range.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="C1.WPF.Excel.XLReferenceType.html">XLReferenceType</a></td>
      <td><span class="parametername">rowToRef</span></td>
      <td><p>The reference type of the bottom row in the range.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="C1.WPF.Excel.XLReferenceType.html">XLReferenceType</a></td>
      <td><span class="parametername">colFromRef</span></td>
      <td><p>The reference type of the left column in the range.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="C1.WPF.Excel.XLReferenceType.html">XLReferenceType</a></td>
      <td><span class="parametername">colToRef</span></td>
      <td><p>The reference type of the right column in the range.</p>
</td>
    </tr>
  </tbody>
</table>


<a id="C1_WPF_Excel_XLCellRange__ctor_" data-uid="C1.WPF.Excel.XLCellRange.#ctor*"></a>
<h4 id="C1_WPF_Excel_XLCellRange__ctor_C1_WPF_Excel_XLSheet_System_Int32_System_Int32_C1_WPF_Excel_XLReferenceType_C1_WPF_Excel_XLReferenceType_" data-uid="C1.WPF.Excel.XLCellRange.#ctor(C1.WPF.Excel.XLSheet,System.Int32,System.Int32,C1.WPF.Excel.XLReferenceType,C1.WPF.Excel.XLReferenceType)">XLCellRange(XLSheet, int, int, XLReferenceType, XLReferenceType)</h4>
<div class="markdown level1 summary"><p>Creates an instance of an <a class="xref" href="C1.WPF.Excel.XLCellRange.html">XLCellRange</a> object containing a specified range.</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="declaration">Declaration</h5>
<div class="codewrapper">
  <pre><code class="lang-csharp hljs">public XLCellRange(XLSheet ws, int row, int col, XLReferenceType rowRef, XLReferenceType colRef)</code></pre>
</div>
<div class="codewrapper">
  <pre><code class="lang-vbnet hljs">Public Sub New(ws As XLSheet, row As Integer, col As Integer, rowRef As XLReferenceType, colRef As XLReferenceType)</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="C1.WPF.Excel.XLSheet.html">XLSheet</a></td>
      <td><span class="parametername">ws</span></td>
      <td><p>The <a class="xref" href="C1.WPF.Excel.XLSheet.html">XLSheet</a> of the range.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.int32">int</a></td>
      <td><span class="parametername">row</span></td>
      <td><p>The row in the range equal one cell.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.int32">int</a></td>
      <td><span class="parametername">col</span></td>
      <td><p>The column in the range equal one cell.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="C1.WPF.Excel.XLReferenceType.html">XLReferenceType</a></td>
      <td><span class="parametername">rowRef</span></td>
      <td><p>The reference type of the row.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="C1.WPF.Excel.XLReferenceType.html">XLReferenceType</a></td>
      <td><span class="parametername">colRef</span></td>
      <td><p>The reference type of the column.</p>
</td>
    </tr>
  </tbody>
</table>


<a id="C1_WPF_Excel_XLCellRange__ctor_" data-uid="C1.WPF.Excel.XLCellRange.#ctor*"></a>
<h4 id="C1_WPF_Excel_XLCellRange__ctor_System_Int32_System_Int32_System_Int32_System_Int32_System_Int32_System_Int32_C1_WPF_Excel_XLReferenceType_C1_WPF_Excel_XLReferenceType_C1_WPF_Excel_XLReferenceType_C1_WPF_Excel_XLReferenceType_" data-uid="C1.WPF.Excel.XLCellRange.#ctor(System.Int32,System.Int32,System.Int32,System.Int32,System.Int32,System.Int32,C1.WPF.Excel.XLReferenceType,C1.WPF.Excel.XLReferenceType,C1.WPF.Excel.XLReferenceType,C1.WPF.Excel.XLReferenceType)">XLCellRange(int, int, int, int, int, int, XLReferenceType, XLReferenceType, XLReferenceType, XLReferenceType)</h4>
<div class="markdown level1 summary"><p>Creates an instance of an <a class="xref" href="C1.WPF.Excel.XLCellRange.html">XLCellRange</a> object containing a specified range.</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="declaration">Declaration</h5>
<div class="codewrapper">
  <pre><code class="lang-csharp hljs">public XLCellRange(int sheetFrom, int sheetTo, int rowFrom, int rowTo, int colFrom, int colTo, XLReferenceType rowFromRef, XLReferenceType rowToRef, XLReferenceType colFromRef, XLReferenceType colToRef)</code></pre>
</div>
<div class="codewrapper">
  <pre><code class="lang-vbnet hljs">Public Sub New(sheetFrom As Integer, sheetTo As Integer, rowFrom As Integer, rowTo As Integer, colFrom As Integer, colTo As Integer, rowFromRef As XLReferenceType, rowToRef As XLReferenceType, colFromRef As XLReferenceType, colToRef As XLReferenceType)</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">sheetFrom</span></td>
      <td><p>First index of the <a class="xref" href="C1.WPF.Excel.XLSheet.html">XLSheet</a> of the range.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.int32">int</a></td>
      <td><span class="parametername">sheetTo</span></td>
      <td><p>Last index of the <a class="xref" href="C1.WPF.Excel.XLSheet.html">XLSheet</a> of the range.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.int32">int</a></td>
      <td><span class="parametername">rowFrom</span></td>
      <td><p>Top row in the range.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.int32">int</a></td>
      <td><span class="parametername">rowTo</span></td>
      <td><p>Bottom row in the range.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.int32">int</a></td>
      <td><span class="parametername">colFrom</span></td>
      <td><p>Left column in the range.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.int32">int</a></td>
      <td><span class="parametername">colTo</span></td>
      <td><p>Right column in the range.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="C1.WPF.Excel.XLReferenceType.html">XLReferenceType</a></td>
      <td><span class="parametername">rowFromRef</span></td>
      <td><p>The reference type of the top row in the range.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="C1.WPF.Excel.XLReferenceType.html">XLReferenceType</a></td>
      <td><span class="parametername">rowToRef</span></td>
      <td><p>The reference type of the bottom row in the range.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="C1.WPF.Excel.XLReferenceType.html">XLReferenceType</a></td>
      <td><span class="parametername">colFromRef</span></td>
      <td><p>The reference type of the left column in the range.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="C1.WPF.Excel.XLReferenceType.html">XLReferenceType</a></td>
      <td><span class="parametername">colToRef</span></td>
      <td><p>The reference type of the right column in the range.</p>
</td>
    </tr>
  </tbody>
</table>


<a id="C1_WPF_Excel_XLCellRange__ctor_" data-uid="C1.WPF.Excel.XLCellRange.#ctor*"></a>
<h4 id="C1_WPF_Excel_XLCellRange__ctor_C1_WPF_Excel_XLSheet_System_String_" data-uid="C1.WPF.Excel.XLCellRange.#ctor(C1.WPF.Excel.XLSheet,System.String)">XLCellRange(XLSheet, string)</h4>
<div class="markdown level1 summary"><p>Creates an instance of an <a class="xref" href="C1.WPF.Excel.XLCellRange.html">XLCellRange</a> object containing a specified range.</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="declaration">Declaration</h5>
<div class="codewrapper">
  <pre><code class="lang-csharp hljs">public XLCellRange(XLSheet sheet, string reference)</code></pre>
</div>
<div class="codewrapper">
  <pre><code class="lang-vbnet hljs">Public Sub New(sheet As XLSheet, reference As String)</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="C1.WPF.Excel.XLSheet.html">XLSheet</a></td>
      <td><span class="parametername">sheet</span></td>
      <td><p>The owner sheet for the range.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.string">string</a></td>
      <td><span class="parametername">reference</span></td>
      <td><p>The text presentation of a specified range without sheets.</p>
</td>
    </tr>
  </tbody>
</table>


<a id="C1_WPF_Excel_XLCellRange__ctor_" data-uid="C1.WPF.Excel.XLCellRange.#ctor*"></a>
<h4 id="C1_WPF_Excel_XLCellRange__ctor_C1_WPF_Excel_C1XLBook_System_String_" data-uid="C1.WPF.Excel.XLCellRange.#ctor(C1.WPF.Excel.C1XLBook,System.String)">XLCellRange(C1XLBook, string)</h4>
<div class="markdown level1 summary"><p>Creates an instance of an <a class="xref" href="C1.WPF.Excel.XLCellRange.html">XLCellRange</a> object containing a specified range.</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="declaration">Declaration</h5>
<div class="codewrapper">
  <pre><code class="lang-csharp hljs">public XLCellRange(C1XLBook book, string reference)</code></pre>
</div>
<div class="codewrapper">
  <pre><code class="lang-vbnet hljs">Public Sub New(book As C1XLBook, reference As String)</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="C1.WPF.Excel.C1XLBook.html">C1XLBook</a></td>
      <td><span class="parametername">book</span></td>
      <td><p>The owner workbook for the range.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.string">string</a></td>
      <td><span class="parametername">reference</span></td>
      <td><p>The text presentation of a specified range.</p>
</td>
    </tr>
  </tbody>
</table>
</div>
