# C1.Win.FlexGrid.CellStyleCollection

## Content

<div class="doc-site-dotnet-api-container">



  <h1 id="C1_Win_FlexGrid_CellStyleCollection" data-uid="C1.Win.FlexGrid.CellStyleCollection" class="text-break">CellStyleCollection Class
</h1>
  <div class="markdown level0 summary"><p>Collection of <a class="xref" href="C1.Win.FlexGrid.CellStyle.html">CellStyle</a> objects defined for a grid.</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">CellStyleCollection</span></div>
  </div>
  <div class="implements">
    <h5>Implements</h5>
    <div><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.collections.icollection">ICollection</a></div>
    <div><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.collections.ienumerable">IEnumerable</a></div>
    <div><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.idisposable">IDisposable</a></div>
  </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_CellStyleCollection_syntax">Syntax</h5>
  <div class="codewrapper">
    <pre><code class="lang-csharp hljs">[TypeConverter(&quot;C1.Win.FlexGrid.Design.GridStyleConverter&quot;)]
public class CellStyleCollection : ICollection, IEnumerable, IDisposable</code></pre>
  </div>
  <div class="codewrapper">
    <pre><code class="lang-vbnet hljs">&lt;TypeConverter(&quot;C1.Win.FlexGrid.Design.GridStyleConverter&quot;)&gt;
Public Class CellStyleCollection
    Implements ICollection, IEnumerable, IDisposable</code></pre>
  </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_CellStyleCollection_Alternate" data-uid="C1.Win.FlexGrid.CellStyleCollection.Alternate">
          <a class="xref" href="C1.Win.FlexGrid.CellStyleCollection.Alternate.html#C1_Win_FlexGrid_CellStyleCollection_Alternate">Alternate</a>
        </td>
        <td class="markdown level1 summary"><p>Gets the style used to paint scrollable cells in alternate rows.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellStyleCollection_Count" data-uid="C1.Win.FlexGrid.CellStyleCollection.Count">
          <a class="xref" href="C1.Win.FlexGrid.CellStyleCollection.Count.html#C1_Win_FlexGrid_CellStyleCollection_Count">Count</a>
        </td>
        <td class="markdown level1 summary"><p>Gets the number of <a class="xref" href="C1.Win.FlexGrid.CellStyle.html">CellStyle</a> objects in the collection.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellStyleCollection_Editor" data-uid="C1.Win.FlexGrid.CellStyleCollection.Editor">
          <a class="xref" href="C1.Win.FlexGrid.CellStyleCollection.Editor.html#C1_Win_FlexGrid_CellStyleCollection_Editor">Editor</a>
        </td>
        <td class="markdown level1 summary"><p>Gets the style used to paint the cell being edited.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellStyleCollection_EmptyArea" data-uid="C1.Win.FlexGrid.CellStyleCollection.EmptyArea">
          <a class="xref" href="C1.Win.FlexGrid.CellStyleCollection.EmptyArea.html#C1_Win_FlexGrid_CellStyleCollection_EmptyArea">EmptyArea</a>
        </td>
        <td class="markdown level1 summary"><p>Gets the style used to paint the area of the grid below and to the right of all the cells.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellStyleCollection_FilterEditor" data-uid="C1.Win.FlexGrid.CellStyleCollection.FilterEditor">
          <a class="xref" href="C1.Win.FlexGrid.CellStyleCollection.FilterEditor.html#C1_Win_FlexGrid_CellStyleCollection_FilterEditor">FilterEditor</a>
        </td>
        <td class="markdown level1 summary"><p>Gets the style used to paint the column filter editors.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellStyleCollection_Fixed" data-uid="C1.Win.FlexGrid.CellStyleCollection.Fixed">
          <a class="xref" href="C1.Win.FlexGrid.CellStyleCollection.Fixed.html#C1_Win_FlexGrid_CellStyleCollection_Fixed">Fixed</a>
        </td>
        <td class="markdown level1 summary"><p>Gets the style used to paint fixed cells.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellStyleCollection_Focus" data-uid="C1.Win.FlexGrid.CellStyleCollection.Focus">
          <a class="xref" href="C1.Win.FlexGrid.CellStyleCollection.Focus.html#C1_Win_FlexGrid_CellStyleCollection_Focus">Focus</a>
        </td>
        <td class="markdown level1 summary"><p>Gets the style used to paint the current cell when the control has focus.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellStyleCollection_Footer" data-uid="C1.Win.FlexGrid.CellStyleCollection.Footer">
          <a class="xref" href="C1.Win.FlexGrid.CellStyleCollection.Footer.html#C1_Win_FlexGrid_CellStyleCollection_Footer">Footer</a>
        </td>
        <td class="markdown level1 summary"><p>Gets the style used to paint the total footers.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellStyleCollection_Frozen" data-uid="C1.Win.FlexGrid.CellStyleCollection.Frozen">
          <a class="xref" href="C1.Win.FlexGrid.CellStyleCollection.Frozen.html#C1_Win_FlexGrid_CellStyleCollection_Frozen">Frozen</a>
        </td>
        <td class="markdown level1 summary"><p>Gets the style used to paint frozen cells (frozen cells are editable and selectable, but not scrollable).</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellStyleCollection_FrozenAlternate" data-uid="C1.Win.FlexGrid.CellStyleCollection.FrozenAlternate">
          <a class="xref" href="C1.Win.FlexGrid.CellStyleCollection.FrozenAlternate.html#C1_Win_FlexGrid_CellStyleCollection_FrozenAlternate">FrozenAlternate</a>
        </td>
        <td class="markdown level1 summary"><p>Gets the style used to paint frozen cells (frozen cells are editable and selectable, but not scrollable) in alternate rows.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellStyleCollection_Highlight" data-uid="C1.Win.FlexGrid.CellStyleCollection.Highlight">
          <a class="xref" href="C1.Win.FlexGrid.CellStyleCollection.Highlight.html#C1_Win_FlexGrid_CellStyleCollection_Highlight">Highlight</a>
        </td>
        <td class="markdown level1 summary"><p>Gets the style used to paint highlighted selected cells.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellStyleCollection_Hover" data-uid="C1.Win.FlexGrid.CellStyleCollection.Hover">
          <a class="xref" href="C1.Win.FlexGrid.CellStyleCollection.Hover.html#C1_Win_FlexGrid_CellStyleCollection_Hover">Hover</a>
        </td>
        <td class="markdown level1 summary"><p>Gets the style used to paint hovered cells.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellStyleCollection_Item_C1_Win_FlexGrid_CellStyleEnum_" data-uid="C1.Win.FlexGrid.CellStyleCollection.Item(C1.Win.FlexGrid.CellStyleEnum)">
          <a class="xref" href="C1.Win.FlexGrid.CellStyleCollection.Item.html#C1_Win_FlexGrid_CellStyleCollection_Item_C1_Win_FlexGrid_CellStyleEnum_">this[CellStyleEnum]</a>
        </td>
        <td class="markdown level1 summary"><p>Gets a built-in <a class="xref" href="C1.Win.FlexGrid.CellStyle.html">CellStyle</a> by style type.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellStyleCollection_Item_System_Int32_" data-uid="C1.Win.FlexGrid.CellStyleCollection.Item(System.Int32)">
          <a class="xref" href="C1.Win.FlexGrid.CellStyleCollection.Item.html#C1_Win_FlexGrid_CellStyleCollection_Item_System_Int32_">this[int]</a>
        </td>
        <td class="markdown level1 summary"><p>Gets a <a class="xref" href="C1.Win.FlexGrid.CellStyle.html">CellStyle</a> by index.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellStyleCollection_Item_System_String_" data-uid="C1.Win.FlexGrid.CellStyleCollection.Item(System.String)">
          <a class="xref" href="C1.Win.FlexGrid.CellStyleCollection.Item.html#C1_Win_FlexGrid_CellStyleCollection_Item_System_String_">this[string]</a>
        </td>
        <td class="markdown level1 summary"><p>Gets a <a class="xref" href="C1.Win.FlexGrid.CellStyle.html">CellStyle</a> by name.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellStyleCollection_NewRow" data-uid="C1.Win.FlexGrid.CellStyleCollection.NewRow">
          <a class="xref" href="C1.Win.FlexGrid.CellStyleCollection.NewRow.html#C1_Win_FlexGrid_CellStyleCollection_NewRow">NewRow</a>
        </td>
        <td class="markdown level1 summary"><p>Gets the style used to paint cells in the new row template at the bottom of the grid.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellStyleCollection_Normal" data-uid="C1.Win.FlexGrid.CellStyleCollection.Normal">
          <a class="xref" href="C1.Win.FlexGrid.CellStyleCollection.Normal.html#C1_Win_FlexGrid_CellStyleCollection_Normal">Normal</a>
        </td>
        <td class="markdown level1 summary"><p>Gets the default style used to paint scrollable cells.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellStyleCollection_Search" data-uid="C1.Win.FlexGrid.CellStyleCollection.Search">
          <a class="xref" href="C1.Win.FlexGrid.CellStyleCollection.Search.html#C1_Win_FlexGrid_CellStyleCollection_Search">Search</a>
        </td>
        <td class="markdown level1 summary"><p>Gets the style used to paint the cell selected while auto-searching.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellStyleCollection_SelectedColumnHeader" data-uid="C1.Win.FlexGrid.CellStyleCollection.SelectedColumnHeader">
          <a class="xref" href="C1.Win.FlexGrid.CellStyleCollection.SelectedColumnHeader.html#C1_Win_FlexGrid_CellStyleCollection_SelectedColumnHeader">SelectedColumnHeader</a>
        </td>
        <td class="markdown level1 summary"><p>Gets the style used to paint selected column headers.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellStyleCollection_SelectedRowHeader" data-uid="C1.Win.FlexGrid.CellStyleCollection.SelectedRowHeader">
          <a class="xref" href="C1.Win.FlexGrid.CellStyleCollection.SelectedRowHeader.html#C1_Win_FlexGrid_CellStyleCollection_SelectedRowHeader">SelectedRowHeader</a>
        </td>
        <td class="markdown level1 summary"><p>Gets the style used to paint selected row headers.</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_CellStyleCollection_Add_System_String_" data-uid="C1.Win.FlexGrid.CellStyleCollection.Add(System.String)">
          <a class="xref" href="C1.Win.FlexGrid.CellStyleCollection.Add.html#C1_Win_FlexGrid_CellStyleCollection_Add_System_String_">Add(string)</a>
        </td>
        <td class="markdown level1 summary"><p>Adds a new empty <a class="xref" href="C1.Win.FlexGrid.CellStyle.html">CellStyle</a> object to the collection.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellStyleCollection_Add_System_String_C1_Win_FlexGrid_CellStyle_" data-uid="C1.Win.FlexGrid.CellStyleCollection.Add(System.String,C1.Win.FlexGrid.CellStyle)">
          <a class="xref" href="C1.Win.FlexGrid.CellStyleCollection.Add.html#C1_Win_FlexGrid_CellStyleCollection_Add_System_String_C1_Win_FlexGrid_CellStyle_">Add(string, CellStyle)</a>
        </td>
        <td class="markdown level1 summary"><p>Adds a new <a class="xref" href="C1.Win.FlexGrid.CellStyle.html">CellStyle</a> object to the collection.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellStyleCollection_Add_System_String_System_String_" data-uid="C1.Win.FlexGrid.CellStyleCollection.Add(System.String,System.String)">
          <a class="xref" href="C1.Win.FlexGrid.CellStyleCollection.Add.html#C1_Win_FlexGrid_CellStyleCollection_Add_System_String_System_String_">Add(string, string)</a>
        </td>
        <td class="markdown level1 summary"><p>Adds new <a class="xref" href="C1.Win.FlexGrid.CellStyle.html">CellStyle</a> object to the collection.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellStyleCollection_BuildString_System_Boolean_" data-uid="C1.Win.FlexGrid.CellStyleCollection.BuildString(System.Boolean)">
          <a class="xref" href="C1.Win.FlexGrid.CellStyleCollection.BuildString.html#C1_Win_FlexGrid_CellStyleCollection_BuildString_System_Boolean_">BuildString(bool)</a>
        </td>
        <td class="markdown level1 summary"><p>Builds and returns a compact string representation of the style collection.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellStyleCollection_Clear" data-uid="C1.Win.FlexGrid.CellStyleCollection.Clear">
          <a class="xref" href="C1.Win.FlexGrid.CellStyleCollection.Clear.html#C1_Win_FlexGrid_CellStyleCollection_Clear">Clear()</a>
        </td>
        <td class="markdown level1 summary"><p>Clear all styles (even those in use) and reset the built-in styles.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellStyleCollection_ClearUnused" data-uid="C1.Win.FlexGrid.CellStyleCollection.ClearUnused">
          <a class="xref" href="C1.Win.FlexGrid.CellStyleCollection.ClearUnused.html#C1_Win_FlexGrid_CellStyleCollection_ClearUnused">ClearUnused()</a>
        </td>
        <td class="markdown level1 summary"><p>Clear all unused styles.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellStyleCollection_Contains_System_String_" data-uid="C1.Win.FlexGrid.CellStyleCollection.Contains(System.String)">
          <a class="xref" href="C1.Win.FlexGrid.CellStyleCollection.Contains.html#C1_Win_FlexGrid_CellStyleCollection_Contains_System_String_">Contains(string)</a>
        </td>
        <td class="markdown level1 summary"><p>Checks whether the collection contains a given style.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellStyleCollection_Dispose" data-uid="C1.Win.FlexGrid.CellStyleCollection.Dispose">
          <a class="xref" href="C1.Win.FlexGrid.CellStyleCollection.Dispose.html#C1_Win_FlexGrid_CellStyleCollection_Dispose">Dispose()</a>
        </td>
        <td class="markdown level1 summary"><p>Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellStyleCollection_Dispose_System_Boolean_" data-uid="C1.Win.FlexGrid.CellStyleCollection.Dispose(System.Boolean)">
          <a class="xref" href="C1.Win.FlexGrid.CellStyleCollection.Dispose.html#C1_Win_FlexGrid_CellStyleCollection_Dispose_System_Boolean_">Dispose(bool)</a>
        </td>
        <td class="markdown level1 summary"><p>Releases unmanaged and - optionally - managed resources.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellStyleCollection_Finalize" data-uid="C1.Win.FlexGrid.CellStyleCollection.Finalize">
          <a class="xref" href="C1.Win.FlexGrid.CellStyleCollection.Finalize.html#C1_Win_FlexGrid_CellStyleCollection_Finalize">~CellStyleCollection()</a>
        </td>
        <td class="markdown level1 summary"><p>Finalizes an instance of the <a class="xref" href="C1.Win.FlexGrid.CellStyleCollection.html">CellStyleCollection</a> class.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellStyleCollection_IndexOf_C1_Win_FlexGrid_CellStyle_" data-uid="C1.Win.FlexGrid.CellStyleCollection.IndexOf(C1.Win.FlexGrid.CellStyle)">
          <a class="xref" href="C1.Win.FlexGrid.CellStyleCollection.IndexOf.html#C1_Win_FlexGrid_CellStyleCollection_IndexOf_C1_Win_FlexGrid_CellStyle_">IndexOf(CellStyle)</a>
        </td>
        <td class="markdown level1 summary"><p>Gets the index of a style in the collection.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellStyleCollection_ParseString_System_String_" data-uid="C1.Win.FlexGrid.CellStyleCollection.ParseString(System.String)">
          <a class="xref" href="C1.Win.FlexGrid.CellStyleCollection.ParseString.html#C1_Win_FlexGrid_CellStyleCollection_ParseString_System_String_">ParseString(string)</a>
        </td>
        <td class="markdown level1 summary"><p>Parses a string containing style definitions.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellStyleCollection_Remove_C1_Win_FlexGrid_CellStyle_" data-uid="C1.Win.FlexGrid.CellStyleCollection.Remove(C1.Win.FlexGrid.CellStyle)">
          <a class="xref" href="C1.Win.FlexGrid.CellStyleCollection.Remove.html#C1_Win_FlexGrid_CellStyleCollection_Remove_C1_Win_FlexGrid_CellStyle_">Remove(CellStyle)</a>
        </td>
        <td class="markdown level1 summary"><p>Removes a custom style from the collection.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellStyleCollection_Remove_System_Int32_" data-uid="C1.Win.FlexGrid.CellStyleCollection.Remove(System.Int32)">
          <a class="xref" href="C1.Win.FlexGrid.CellStyleCollection.Remove.html#C1_Win_FlexGrid_CellStyleCollection_Remove_System_Int32_">Remove(int)</a>
        </td>
        <td class="markdown level1 summary"><p>Removes a custom style from the collection.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Win_FlexGrid_CellStyleCollection_Remove_System_String_" data-uid="C1.Win.FlexGrid.CellStyleCollection.Remove(System.String)">
          <a class="xref" href="C1.Win.FlexGrid.CellStyleCollection.Remove.html#C1_Win_FlexGrid_CellStyleCollection_Remove_System_String_">Remove(string)</a>
        </td>
        <td class="markdown level1 summary"><p>Removes a custom style from the collection.</p>
</td>
      </tr>
    </tbody>
  </table>

</div>
