# FarPoint.Win.Spread.Model.DefaultSheetDataModel.AddCustomName

## Content

<div class="doc-site-dotnet-api-container">



<h1 id="FarPoint_Win_Spread_Model_DefaultSheetDataModel_AddCustomName_" data-uid="FarPoint.Win.Spread.Model.DefaultSheetDataModel.AddCustomName*">AddCustomName Method
</h1>
<div class="markdown level0 summary"></div>
<div class="markdown level0 conceptual"></div>



<a id="FarPoint_Win_Spread_Model_DefaultSheetDataModel_AddCustomName_" data-uid="FarPoint.Win.Spread.Model.DefaultSheetDataModel.AddCustomName*"></a>
<h4 id="FarPoint_Win_Spread_Model_DefaultSheetDataModel_AddCustomName_System_String_System_String_System_Int32_System_Int32_" data-uid="FarPoint.Win.Spread.Model.DefaultSheetDataModel.AddCustomName(System.String,System.String,System.Int32,System.Int32)">AddCustomName(string, string, int, int)</h4>
<div class="markdown level1 summary"><p>Adds a named expression to the model for use in formulas.</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="declaration">Declaration</h5>
<div class="codewrapper">
  <pre><code class="lang-csharp hljs">public void AddCustomName(string name, string value, int baseRow, int baseColumn)</code></pre>
</div>
<div class="codewrapper">
  <pre><code class="lang-vbnet hljs">Public Sub AddCustomName(name As String, value As String, baseRow As Integer, baseColumn 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.string">string</a></td>
      <td><span class="parametername">name</span></td>
      <td><p>Name of the expression to add (used in formulas to reference the value)</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.string">string</a></td>
      <td><span class="parametername">value</span></td>
      <td><p>Value of the expression (used in formulas for evaluation)</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.int32">int</a></td>
      <td><span class="parametername">baseRow</span></td>
      <td><p>Base row index for computing relative cell references</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.int32">int</a></td>
      <td><span class="parametername">baseColumn</span></td>
      <td><p>Base column index for computing relative cell references</p>
</td>
    </tr>
  </tbody>
</table>
<h5 class="implements">Implements</h5>
    <div><a class="xref" href="FarPoint.Win.Spread.Model.ICustomNameSupport.AddCustomName.html#FarPoint_Win_Spread_Model_ICustomNameSupport_AddCustomName_System_String_System_String_System_Int32_System_Int32_">ICustomNameSupport.AddCustomName(string, string, int, int)</a></div>


<a id="FarPoint_Win_Spread_Model_DefaultSheetDataModel_AddCustomName_" data-uid="FarPoint.Win.Spread.Model.DefaultSheetDataModel.AddCustomName*"></a>
<h4 id="FarPoint_Win_Spread_Model_DefaultSheetDataModel_AddCustomName_System_String_System_String_System_Int32_System_Int32_System_String_" data-uid="FarPoint.Win.Spread.Model.DefaultSheetDataModel.AddCustomName(System.String,System.String,System.Int32,System.Int32,System.String)">AddCustomName(string, string, int, int, string)</h4>
<div class="markdown level1 summary"><p>Adds a new user-defined name to the model using the specified string value.</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="declaration">Declaration</h5>
<div class="codewrapper">
  <pre><code class="lang-csharp hljs">public void AddCustomName(string name, string value, int baseRow, int baseColumn, string comment)</code></pre>
</div>
<div class="codewrapper">
  <pre><code class="lang-vbnet hljs">Public Sub AddCustomName(name As String, value As String, baseRow As Integer, baseColumn As Integer, comment 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="https://learn.microsoft.com/dotnet/api/system.string">string</a></td>
      <td><span class="parametername">name</span></td>
      <td><p>Name to add</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.string">string</a></td>
      <td><span class="parametername">value</span></td>
      <td><p>Value for name, as string</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.int32">int</a></td>
      <td><span class="parametername">baseRow</span></td>
      <td><p>Base row index for calculating relative row references in the value</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.int32">int</a></td>
      <td><span class="parametername">baseColumn</span></td>
      <td><p>Base column index for calculating relative column references in the value</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.string">string</a></td>
      <td><span class="parametername">comment</span></td>
      <td><p>Comment for the custom name</p>
</td>
    </tr>
  </tbody>
</table>
<h5 class="implements">Implements</h5>
    <div><a class="xref" href="FarPoint.Win.Spread.Model.IEnhancedCustomNameSupport.AddCustomName.html#FarPoint_Win_Spread_Model_IEnhancedCustomNameSupport_AddCustomName_System_String_System_String_System_Int32_System_Int32_System_String_">IEnhancedCustomNameSupport.AddCustomName(string, string, int, int, string)</a></div>
</div>
