# GrapeCity.Spreadsheet.IFormatConditions.AddColorScale

## Content

<div class="doc-site-dotnet-api-container">



<h1 id="GrapeCity_Spreadsheet_IFormatConditions_AddColorScale_" data-uid="GrapeCity.Spreadsheet.IFormatConditions.AddColorScale*">AddColorScale Method
</h1>
<div class="markdown level0 summary"></div>
<div class="markdown level0 conceptual"></div>



<a id="GrapeCity_Spreadsheet_IFormatConditions_AddColorScale_" data-uid="GrapeCity.Spreadsheet.IFormatConditions.AddColorScale*"></a>
<h4 id="GrapeCity_Spreadsheet_IFormatConditions_AddColorScale_System_Int32_" data-uid="GrapeCity.Spreadsheet.IFormatConditions.AddColorScale(System.Int32)">AddColorScale(int)</h4>
<div class="markdown level1 summary"><p>Returns a new <a class="xref" href="GrapeCity.Spreadsheet.IColorScale.html">IColorScale</a> object representing a conditional formatting rule that uses gradations in cell colors to indicate relative differences in the values of cells included in a selected range.</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="declaration">Declaration</h5>
<div class="codewrapper">
  <pre><code class="lang-csharp hljs">IColorScale AddColorScale(int colorScales)</code></pre>
</div>
<div class="codewrapper">
  <pre><code class="lang-vbnet hljs">Function AddColorScale(colorScales As Integer) As IColorScale</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">colorScales</span></td>
      <td><p>An integer value that indicates the number of color scales.</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="GrapeCity.Spreadsheet.IColorScale.html">IColorScale</a></td>
      <td><p>A new <a class="xref" href="GrapeCity.Spreadsheet.IColorScale.html">IColorScale</a> object representing a conditional formatting rule that uses gradations in cell colors.</p>
</td>
    </tr>
  </tbody>
</table>
</div>
