# C1.Win.FlexGrid.CellRange

## Content

<div class="doc-site-dotnet-api-container">



  <h1 id="C1_Win_FlexGrid_CellRange" data-uid="C1.Win.FlexGrid.CellRange" class="text-break">CellRange Struct
</h1>
  <div class="markdown level0 summary"><p>Represents cell ranges, allowing the caller to set properties for multiple cells
with a single statement.</p>
</div>
  <div class="markdown level0 conceptual"></div>
  <h6><strong>Namespace</strong>: <a class="xref" href="C1.Win.FlexGrid.html">C1.Win.FlexGrid</a></h6>
  <h6><strong>Assembly</strong>: C1.Win.FlexGrid.10.dll</h6>
  <h5 id="C1_Win_FlexGrid_CellRange_syntax">Syntax</h5>
  <div class="codewrapper">
    <pre><code class="lang-csharp hljs">public struct CellRange</code></pre>
  </div>
  <div class="codewrapper">
    <pre><code class="lang-vbnet hljs">Public Structure CellRange</code></pre>
  </div>
  <h5 id="C1_Win_FlexGrid_CellRange_remarks"><strong>Remarks</strong></h5>
  <div class="markdown level0 remarks"><p>The <a class="xref" href="C1.Win.FlexGrid.CellRange.html">CellRange</a> structure does not have a public constructor. To create a <a class="xref" href="C1.Win.FlexGrid.CellRange.html">CellRange</a> 
object, use the <a class="xref" href="C1.Win.FlexGrid.C1FlexGridBase.GetCellRange.html#C1_Win_FlexGrid_C1FlexGridBase_GetCellRange_System_Int32_System_Int32_">GetCellRange(int, int)</a> method.</p>
<p>Note that <a class="xref" href="C1.Win.FlexGrid.CellRange.html">CellRange</a> is a structure, not a class. This means the object is used as a value, 
not as a reference. If you pass a <a class="xref" href="C1.Win.FlexGrid.CellRange.html">CellRange</a> to a method and change the object within that method, 
the original value is not modified.</p>
<p>Ranges are defined by two rows and two columns (<a class="xref" href="C1.Win.FlexGrid.CellRange.r1.html#C1_Win_FlexGrid_CellRange_r1">r1</a>, <a class="xref" href="C1.Win.FlexGrid.CellRange.c1.html#C1_Win_FlexGrid_CellRange_c1">c1</a>, <a class="xref" href="C1.Win.FlexGrid.CellRange.r2.html#C1_Win_FlexGrid_CellRange_r2">r2</a>, and
<a class="xref" href="C1.Win.FlexGrid.CellRange.c2.html#C1_Win_FlexGrid_CellRange_c2">c2</a>). These values do not have to be in order (<a class="xref" href="C1.Win.FlexGrid.CellRange.r1.html#C1_Win_FlexGrid_CellRange_r1">r1</a> may be smaller or greater than 
<a class="xref" href="C1.Win.FlexGrid.CellRange.r2.html#C1_Win_FlexGrid_CellRange_r2">r2</a>). To obtain the values in order, use the <a class="xref" href="C1.Win.FlexGrid.CellRange.Normalize.html#C1_Win_FlexGrid_CellRange_Normalize">Normalize()</a> method or the <a class="xref" href="C1.Win.FlexGrid.CellRange.TopRow.html#C1_Win_FlexGrid_CellRange_TopRow">TopRow</a>,
<a class="xref" href="C1.Win.FlexGrid.CellRange.BottomRow.html#C1_Win_FlexGrid_CellRange_BottomRow">BottomRow</a>, <a class="xref" href="C1.Win.FlexGrid.CellRange.LeftCol.html#C1_Win_FlexGrid_CellRange_LeftCol">LeftCol</a>, and <a class="xref" href="C1.Win.FlexGrid.CellRange.RightCol.html#C1_Win_FlexGrid_CellRange_RightCol">RightCol</a> properties.</p>
</div>
  <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_Win_FlexGrid_CellRange_BottomRow" data-uid="C1.Win.FlexGrid.CellRange.BottomRow">
          <a class="xref" href="C1.Win.FlexGrid.CellRange.BottomRow.html#C1_Win_FlexGrid_CellRange_BottomRow">BottomRow</a>
        </td>
        <td class="markdown level1 summary"><p>Gets the index of the bottom row in the range.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellRange_Checkbox" data-uid="C1.Win.FlexGrid.CellRange.Checkbox">
          <a class="xref" href="C1.Win.FlexGrid.CellRange.Checkbox.html#C1_Win_FlexGrid_CellRange_Checkbox">Checkbox</a>
        </td>
        <td class="markdown level1 summary"><p>Gets or sets the state of the checkbox in the range.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellRange_Clip" data-uid="C1.Win.FlexGrid.CellRange.Clip">
          <a class="xref" href="C1.Win.FlexGrid.CellRange.Clip.html#C1_Win_FlexGrid_CellRange_Clip">Clip</a>
        </td>
        <td class="markdown level1 summary"><p>Gets or sets a string containing the values of all cells in the range.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellRange_Data" data-uid="C1.Win.FlexGrid.CellRange.Data">
          <a class="xref" href="C1.Win.FlexGrid.CellRange.Data.html#C1_Win_FlexGrid_CellRange_Data">Data</a>
        </td>
        <td class="markdown level1 summary"><p>Gets or sets the data stored in the range.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellRange_DataDisplay" data-uid="C1.Win.FlexGrid.CellRange.DataDisplay">
          <a class="xref" href="C1.Win.FlexGrid.CellRange.DataDisplay.html#C1_Win_FlexGrid_CellRange_DataDisplay">DataDisplay</a>
        </td>
        <td class="markdown level1 summary"><p>Gets the value in cell (<a class="xref" href="C1.Win.FlexGrid.CellRange.r1.html#C1_Win_FlexGrid_CellRange_r1">r1</a>, <a class="xref" href="C1.Win.FlexGrid.CellRange.c1.html#C1_Win_FlexGrid_CellRange_c1">c1</a>), formatted as a string.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellRange_Image" data-uid="C1.Win.FlexGrid.CellRange.Image">
          <a class="xref" href="C1.Win.FlexGrid.CellRange.Image.html#C1_Win_FlexGrid_CellRange_Image">Image</a>
        </td>
        <td class="markdown level1 summary"><p>Gets or sets the <a class="xref" href="C1.Win.FlexGrid.CellRange.Image.html#C1_Win_FlexGrid_CellRange_Image">Image</a> assigned to cells in the range.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellRange_IsSingleCell" data-uid="C1.Win.FlexGrid.CellRange.IsSingleCell">
          <a class="xref" href="C1.Win.FlexGrid.CellRange.IsSingleCell.html#C1_Win_FlexGrid_CellRange_IsSingleCell">IsSingleCell</a>
        </td>
        <td class="markdown level1 summary"><p>Gets a value that indicates if the range contains a single cell.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellRange_IsSingleColumn" data-uid="C1.Win.FlexGrid.CellRange.IsSingleColumn">
          <a class="xref" href="C1.Win.FlexGrid.CellRange.IsSingleColumn.html#C1_Win_FlexGrid_CellRange_IsSingleColumn">IsSingleColumn</a>
        </td>
        <td class="markdown level1 summary"><p>Gets a value that indicates if the range contains a single column.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellRange_IsSingleRow" data-uid="C1.Win.FlexGrid.CellRange.IsSingleRow">
          <a class="xref" href="C1.Win.FlexGrid.CellRange.IsSingleRow.html#C1_Win_FlexGrid_CellRange_IsSingleRow">IsSingleRow</a>
        </td>
        <td class="markdown level1 summary"><p>Gets a value that indicates if the range contains a single row.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellRange_IsValid" data-uid="C1.Win.FlexGrid.CellRange.IsValid">
          <a class="xref" href="C1.Win.FlexGrid.CellRange.IsValid.html#C1_Win_FlexGrid_CellRange_IsValid">IsValid</a>
        </td>
        <td class="markdown level1 summary"><p>Gets a value that indicates if the range contains valid row and column indices.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellRange_LeftCol" data-uid="C1.Win.FlexGrid.CellRange.LeftCol">
          <a class="xref" href="C1.Win.FlexGrid.CellRange.LeftCol.html#C1_Win_FlexGrid_CellRange_LeftCol">LeftCol</a>
        </td>
        <td class="markdown level1 summary"><p>Gets the index of the left column in the range.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellRange_RightCol" data-uid="C1.Win.FlexGrid.CellRange.RightCol">
          <a class="xref" href="C1.Win.FlexGrid.CellRange.RightCol.html#C1_Win_FlexGrid_CellRange_RightCol">RightCol</a>
        </td>
        <td class="markdown level1 summary"><p>Gets the index of the right column in the range.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellRange_Style" data-uid="C1.Win.FlexGrid.CellRange.Style">
          <a class="xref" href="C1.Win.FlexGrid.CellRange.Style.html#C1_Win_FlexGrid_CellRange_Style">Style</a>
        </td>
        <td class="markdown level1 summary"><p>Gets or sets the style used to display every cell in the range.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellRange_StyleDisplay" data-uid="C1.Win.FlexGrid.CellRange.StyleDisplay">
          <a class="xref" href="C1.Win.FlexGrid.CellRange.StyleDisplay.html#C1_Win_FlexGrid_CellRange_StyleDisplay">StyleDisplay</a>
        </td>
        <td class="markdown level1 summary"><p>Gets the style used to render cell (<a class="xref" href="C1.Win.FlexGrid.CellRange.r1.html#C1_Win_FlexGrid_CellRange_r1">r1</a>, <a class="xref" href="C1.Win.FlexGrid.CellRange.c1.html#C1_Win_FlexGrid_CellRange_c1">c1</a>).</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellRange_StyleNew" data-uid="C1.Win.FlexGrid.CellRange.StyleNew">
          <a class="xref" href="C1.Win.FlexGrid.CellRange.StyleNew.html#C1_Win_FlexGrid_CellRange_StyleNew">StyleNew</a>
        </td>
        <td class="markdown level1 summary"><p>Gets or sets the style used to display every cell in the range, creating a new style if necessary.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellRange_TopRow" data-uid="C1.Win.FlexGrid.CellRange.TopRow">
          <a class="xref" href="C1.Win.FlexGrid.CellRange.TopRow.html#C1_Win_FlexGrid_CellRange_TopRow">TopRow</a>
        </td>
        <td class="markdown level1 summary"><p>Gets the index of the top row in the range.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellRange_UserData" data-uid="C1.Win.FlexGrid.CellRange.UserData">
          <a class="xref" href="C1.Win.FlexGrid.CellRange.UserData.html#C1_Win_FlexGrid_CellRange_UserData">UserData</a>
        </td>
        <td class="markdown level1 summary"><p>Gets or sets arbitrary used data assigned to cells in the range.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellRange_c1" data-uid="C1.Win.FlexGrid.CellRange.c1">
          <a class="xref" href="C1.Win.FlexGrid.CellRange.c1.html#C1_Win_FlexGrid_CellRange_c1">c1</a>
        </td>
        <td class="markdown level1 summary"><p>Gets or sets the range's first column index.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellRange_c2" data-uid="C1.Win.FlexGrid.CellRange.c2">
          <a class="xref" href="C1.Win.FlexGrid.CellRange.c2.html#C1_Win_FlexGrid_CellRange_c2">c2</a>
        </td>
        <td class="markdown level1 summary"><p>Gets or sets the range's last column index.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellRange_r1" data-uid="C1.Win.FlexGrid.CellRange.r1">
          <a class="xref" href="C1.Win.FlexGrid.CellRange.r1.html#C1_Win_FlexGrid_CellRange_r1">r1</a>
        </td>
        <td class="markdown level1 summary"><p>Gets or sets the range's first row index.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellRange_r2" data-uid="C1.Win.FlexGrid.CellRange.r2">
          <a class="xref" href="C1.Win.FlexGrid.CellRange.r2.html#C1_Win_FlexGrid_CellRange_r2">r2</a>
        </td>
        <td class="markdown level1 summary"><p>Gets or sets the range's last row index.</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_Win_FlexGrid_CellRange_Clear_C1_Win_FlexGrid_ClearFlags_" data-uid="C1.Win.FlexGrid.CellRange.Clear(C1.Win.FlexGrid.ClearFlags)">
          <a class="xref" href="C1.Win.FlexGrid.CellRange.Clear.html#C1_Win_FlexGrid_CellRange_Clear_C1_Win_FlexGrid_ClearFlags_">Clear(ClearFlags)</a>
        </td>
        <td class="markdown level1 summary"><p>Clears selected elements from the range.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellRange_Contains_System_Int32_System_Int32_" data-uid="C1.Win.FlexGrid.CellRange.Contains(System.Int32,System.Int32)">
          <a class="xref" href="C1.Win.FlexGrid.CellRange.Contains.html#C1_Win_FlexGrid_CellRange_Contains_System_Int32_System_Int32_">Contains(int, int)</a>
        </td>
        <td class="markdown level1 summary"><p>Determines whether the range contains a given cell.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellRange_ContainsCol_System_Int32_" data-uid="C1.Win.FlexGrid.CellRange.ContainsCol(System.Int32)">
          <a class="xref" href="C1.Win.FlexGrid.CellRange.ContainsCol.html#C1_Win_FlexGrid_CellRange_ContainsCol_System_Int32_">ContainsCol(int)</a>
        </td>
        <td class="markdown level1 summary"><p>Determines whether the range contains a given column.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellRange_ContainsRow_System_Int32_" data-uid="C1.Win.FlexGrid.CellRange.ContainsRow(System.Int32)">
          <a class="xref" href="C1.Win.FlexGrid.CellRange.ContainsRow.html#C1_Win_FlexGrid_CellRange_ContainsRow_System_Int32_">ContainsRow(int)</a>
        </td>
        <td class="markdown level1 summary"><p>Determines whether the range contains a given row.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellRange_Equals_System_Object_" data-uid="C1.Win.FlexGrid.CellRange.Equals(System.Object)">
          <a class="xref" href="C1.Win.FlexGrid.CellRange.Equals.html#C1_Win_FlexGrid_CellRange_Equals_System_Object_">Equals(object)</a>
        </td>
        <td class="markdown level1 summary"><p>Indicates whether this CellRange and a specified CellRange are equal.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellRange_GetHashCode" data-uid="C1.Win.FlexGrid.CellRange.GetHashCode">
          <a class="xref" href="C1.Win.FlexGrid.CellRange.GetHashCode.html#C1_Win_FlexGrid_CellRange_GetHashCode">GetHashCode()</a>
        </td>
        <td class="markdown level1 summary"><p>Gets a hash code for the CellRange.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellRange_Normalize" data-uid="C1.Win.FlexGrid.CellRange.Normalize">
          <a class="xref" href="C1.Win.FlexGrid.CellRange.Normalize.html#C1_Win_FlexGrid_CellRange_Normalize">Normalize()</a>
        </td>
        <td class="markdown level1 summary"><p>Normalizes the range so that <a class="xref" href="C1.Win.FlexGrid.CellRange.r1.html#C1_Win_FlexGrid_CellRange_r1">r1</a> is the <a class="xref" href="C1.Win.FlexGrid.CellRange.TopRow.html#C1_Win_FlexGrid_CellRange_TopRow">TopRow</a>,
<a class="xref" href="C1.Win.FlexGrid.CellRange.r2.html#C1_Win_FlexGrid_CellRange_r2">r2</a> is the <a class="xref" href="C1.Win.FlexGrid.CellRange.BottomRow.html#C1_Win_FlexGrid_CellRange_BottomRow">BottomRow</a>,
<a class="xref" href="C1.Win.FlexGrid.CellRange.c1.html#C1_Win_FlexGrid_CellRange_c1">c1</a> is the <a class="xref" href="C1.Win.FlexGrid.CellRange.LeftCol.html#C1_Win_FlexGrid_CellRange_LeftCol">LeftCol</a>,
and <a class="xref" href="C1.Win.FlexGrid.CellRange.c2.html#C1_Win_FlexGrid_CellRange_c2">c2</a> is the <a class="xref" href="C1.Win.FlexGrid.CellRange.RightCol.html#C1_Win_FlexGrid_CellRange_RightCol">RightCol</a>.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellRange_ToString" data-uid="C1.Win.FlexGrid.CellRange.ToString">
          <a class="xref" href="C1.Win.FlexGrid.CellRange.ToString.html#C1_Win_FlexGrid_CellRange_ToString">ToString()</a>
        </td>
        <td class="markdown level1 summary"><p>Gets a string representation for this object.</p>
</td>
      </tr>
    </tbody>
  </table>
  <h3 id="operators">Operators
</h3>
  <table class="table table-bordered table-condensed">
    <thead>
      <tr>
        <th>Name</th>
        <th>Description</th>
      </tr>
    </thead>
    <tbody>
      <tr>
        <td id="C1_Win_FlexGrid_CellRange_op_Equality_C1_Win_FlexGrid_CellRange_C1_Win_FlexGrid_CellRange_" data-uid="C1.Win.FlexGrid.CellRange.op_Equality(C1.Win.FlexGrid.CellRange,C1.Win.FlexGrid.CellRange)">
          <a class="xref" href="C1.Win.FlexGrid.CellRange.op_Equality.html#C1_Win_FlexGrid_CellRange_op_Equality_C1_Win_FlexGrid_CellRange_C1_Win_FlexGrid_CellRange_">operator ==(CellRange, CellRange)</a>
        </td>
        <td class="markdown level1 summary"><p>Checks if operands are equal.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellRange_op_Inequality_C1_Win_FlexGrid_CellRange_C1_Win_FlexGrid_CellRange_" data-uid="C1.Win.FlexGrid.CellRange.op_Inequality(C1.Win.FlexGrid.CellRange,C1.Win.FlexGrid.CellRange)">
          <a class="xref" href="C1.Win.FlexGrid.CellRange.op_Inequality.html#C1_Win_FlexGrid_CellRange_op_Inequality_C1_Win_FlexGrid_CellRange_C1_Win_FlexGrid_CellRange_">operator !=(CellRange, CellRange)</a>
        </td>
        <td class="markdown level1 summary"><p>Checks if operands are not equal.</p>
</td>
      </tr>
    </tbody>
  </table>

</div>
