# C1.Web.Mvc.InputMask

## Content

<div class="doc-site-dotnet-api-container">



  <h1 id="C1_Web_Mvc_InputMask" data-uid="C1.Web.Mvc.InputMask" class="text-break">InputMask Class
</h1>
  <div class="markdown level0 summary"><p>The InputMask control provides a way to govern what a user is allowed to input.</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"><a class="xref" href="C1.Web.Mvc.Component.html">Component</a></div>
    <div class="level2"><a class="xref" href="C1.Web.Mvc.Control.html">Control</a></div>
    <div class="level3"><a class="xref" href="C1.Web.Mvc.InputBase.html">InputBase</a></div>
    <div class="level4"><a class="xref" href="C1.Web.Mvc.FormInputBase.html">FormInputBase</a></div>
    <div class="level5"><span class="xref">InputMask</span></div>
  </div>
  <div class="implements">
    <h5>Implements</h5>
    <div><a class="xref" href="https://learn.microsoft.com/dotnet/api/microsoft.aspnetcore.html.ihtmlcontent">IHtmlContent</a></div>
    <div><a class="xref" href="C1.Web.Mvc.ITemplate.html">ITemplate</a></div>
  </div>
  <h6><strong>Namespace</strong>: <a class="xref" href="C1.Web.Mvc.html">C1.Web.Mvc</a></h6>
  <h6><strong>Assembly</strong>: C1.AspNetCore.Mvc.dll</h6>
  <h5 id="C1_Web_Mvc_InputMask_syntax">Syntax</h5>
  <div class="codewrapper">
    <pre><code class="lang-csharp hljs">public class InputMask : FormInputBase, IHtmlContent, ITemplate</code></pre>
  </div>
  <div class="codewrapper">
    <pre><code class="lang-vbnet hljs">Public Class InputMask
    Inherits FormInputBase
    Implements IHtmlContent, ITemplate</code></pre>
  </div>
  <h3 id="constructors">Constructors
</h3>
  <table class="table table-bordered table-condensed">
    <thead>
      <tr>
        <th>Name</th>
        <th>Description</th>
      </tr>
    </thead>
    <tbody>
      <tr>
        <td id="C1_Web_Mvc_InputMask__ctor_Microsoft_AspNetCore_Mvc_Rendering_IHtmlHelper_System_String_" data-uid="C1.Web.Mvc.InputMask.#ctor(Microsoft.AspNetCore.Mvc.Rendering.IHtmlHelper,System.String)">
          <a class="xref" href="C1.Web.Mvc.InputMask.-ctor.html#C1_Web_Mvc_InputMask__ctor_Microsoft_AspNetCore_Mvc_Rendering_IHtmlHelper_System_String_">InputMask(IHtmlHelper, string)</a>
        </td>
        <td class="markdown level1 summary"><p>Creates one <a class="xref" href="C1.Web.Mvc.InputMask.html">InputMask</a> instance.</p>
</td>
      </tr>
    </tbody>
  </table>
  <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_Web_Mvc_InputMask_InputType" data-uid="C1.Web.Mvc.InputMask.InputType">
          <a class="xref" href="C1.Web.Mvc.InputMask.InputType.html#C1_Web_Mvc_InputMask_InputType">InputType</a>
        </td>
        <td class="markdown level1 summary"><p>Gets or sets the &quot;type&quot; attribute of the HTML input element hosted by the control.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Web_Mvc_InputMask_IsReadOnly" data-uid="C1.Web.Mvc.InputMask.IsReadOnly">
          <a class="xref" href="C1.Web.Mvc.InputMask.IsReadOnly.html#C1_Web_Mvc_InputMask_IsReadOnly">IsReadOnly</a>
        </td>
        <td class="markdown level1 summary"><p>Gets or sets a value that indicates whether the user can modify the control value using the mouse and keyboard.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Web_Mvc_InputMask_IsRequired" data-uid="C1.Web.Mvc.InputMask.IsRequired">
          <a class="xref" href="C1.Web.Mvc.InputMask.IsRequired.html#C1_Web_Mvc_InputMask_IsRequired">IsRequired</a>
        </td>
        <td class="markdown level1 summary"><p>Gets or sets a value indicating whether the control value must be a non-empty string.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Web_Mvc_InputMask_Mask" data-uid="C1.Web.Mvc.InputMask.Mask">
          <a class="xref" href="C1.Web.Mvc.InputMask.Mask.html#C1_Web_Mvc_InputMask_Mask">Mask</a>
        </td>
        <td class="markdown level1 summary"><p>Gets or sets the mask used to validate the input as the user types.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Web_Mvc_InputMask_OnClientInvalidInput" data-uid="C1.Web.Mvc.InputMask.OnClientInvalidInput">
          <a class="xref" href="C1.Web.Mvc.InputMask.OnClientInvalidInput.html#C1_Web_Mvc_InputMask_OnClientInvalidInput">OnClientInvalidInput</a>
        </td>
        <td class="markdown level1 summary"><p>Occurs when invalid input is detected.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Web_Mvc_InputMask_OnClientValueChanged" data-uid="C1.Web.Mvc.InputMask.OnClientValueChanged">
          <a class="xref" href="C1.Web.Mvc.InputMask.OnClientValueChanged.html#C1_Web_Mvc_InputMask_OnClientValueChanged">OnClientValueChanged</a>
        </td>
        <td class="markdown level1 summary"><p>Occurs when the value of the Value property changes.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Web_Mvc_InputMask_OverwriteMode" data-uid="C1.Web.Mvc.InputMask.OverwriteMode">
          <a class="xref" href="C1.Web.Mvc.InputMask.OverwriteMode.html#C1_Web_Mvc_InputMask_OverwriteMode">OverwriteMode</a>
        </td>
        <td class="markdown level1 summary"><p>Gets or sets a value that determines whether the input element handles input in overwrite mode. In <strong>overwrite mode</strong>, every character you type is displayed at the cursor position. If a character is already at that position, it is replaced.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Web_Mvc_InputMask_Placeholder" data-uid="C1.Web.Mvc.InputMask.Placeholder">
          <a class="xref" href="C1.Web.Mvc.InputMask.Placeholder.html#C1_Web_Mvc_InputMask_Placeholder">Placeholder</a>
        </td>
        <td class="markdown level1 summary"><p>Gets or sets the string shown as a hint when the control is empty.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Web_Mvc_InputMask_PromptChar" data-uid="C1.Web.Mvc.InputMask.PromptChar">
          <a class="xref" href="C1.Web.Mvc.InputMask.PromptChar.html#C1_Web_Mvc_InputMask_PromptChar">PromptChar</a>
        </td>
        <td class="markdown level1 summary"><p>Gets or sets the symbol used to show input positions in the control.</p>
</td>
      </tr>
      <tr>
        <td id="C1_Web_Mvc_InputMask_RawValue" data-uid="C1.Web.Mvc.InputMask.RawValue">
          <a class="xref" href="C1.Web.Mvc.InputMask.RawValue.html#C1_Web_Mvc_InputMask_RawValue">RawValue</a>
        </td>
        <td class="markdown level1 summary"><p>Gets or sets the raw value of the control (excluding mask literals).</p>
</td>
      </tr>
      <tr>
        <td id="C1_Web_Mvc_InputMask_Value" data-uid="C1.Web.Mvc.InputMask.Value">
          <a class="xref" href="C1.Web.Mvc.InputMask.Value.html#C1_Web_Mvc_InputMask_Value">Value</a>
        </td>
        <td class="markdown level1 summary"><p>Gets or sets the text currently shown in the control.</p>
</td>
      </tr>
    </tbody>
  </table>

</div>
