# C1.C1Preview.LineDef.Parse

## Content

<div class="doc-site-dotnet-api-container">



<h1 id="C1_C1Preview_LineDef_Parse_" data-uid="C1.C1Preview.LineDef.Parse*">Parse Method
</h1>
<div class="markdown level0 summary"></div>
<div class="markdown level0 conceptual"></div>



<a id="C1_C1Preview_LineDef_Parse_" data-uid="C1.C1Preview.LineDef.Parse*"></a>
<h4 id="C1_C1Preview_LineDef_Parse_System_String_System_Boolean_" data-uid="C1.C1Preview.LineDef.Parse(System.String,System.Boolean)">Parse(string, bool)</h4>
<div class="markdown level1 summary"><p>Creates a <a class="xref" href="C1.C1Preview.LineDef.html">LineDef</a> object, and initialises it with values
acquired by parsing a string representation of a <a class="xref" href="C1.C1Preview.LineDef.html">LineDef</a>.</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="declaration">Declaration</h5>
<div class="codewrapper">
  <pre><code class="lang-csharp hljs">public static LineDef Parse(string s, bool throwOnError)</code></pre>
</div>
<div class="codewrapper">
  <pre><code class="lang-vbnet hljs">Public Shared Function Parse(s As String, throwOnError As Boolean) As LineDef</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">s</span></td>
      <td><p>A string representing a <a class="xref" href="C1.C1Preview.LineDef.html">LineDef</a> (see <a class="xref" href="C1.C1Preview.LineDef.ToString.html#C1_C1Preview_LineDef_ToString">ToString()</a>).</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.boolean">bool</a></td>
      <td><span class="parametername">throwOnError</span></td>
      <td><p>If <b>true</b>, an exception is thrown if an error occurs while parsing; otherwise, errors are ignored.</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="C1.C1Preview.LineDef.html">LineDef</a></td>
      <td><p>The new <a class="xref" href="C1.C1Preview.LineDef.html">LineDef</a> object.</p>
</td>
    </tr>
  </tbody>
</table>


<a id="C1_C1Preview_LineDef_Parse_" data-uid="C1.C1Preview.LineDef.Parse*"></a>
<h4 id="C1_C1Preview_LineDef_Parse_System_String_System_Boolean_System_ComponentModel_ITypeDescriptorContext_" data-uid="C1.C1Preview.LineDef.Parse(System.String,System.Boolean,System.ComponentModel.ITypeDescriptorContext)">Parse(string, bool, ITypeDescriptorContext)</h4>
<div class="markdown level1 summary"><p>For internal use only.</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="declaration">Declaration</h5>
<div class="codewrapper">
  <pre><code class="lang-csharp hljs">public static LineDef Parse(string s, bool throwOnError, ITypeDescriptorContext context)</code></pre>
</div>
<div class="codewrapper">
  <pre><code class="lang-vbnet hljs">Public Shared Function Parse(s As String, throwOnError As Boolean, context As ITypeDescriptorContext) As LineDef</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">s</span></td>
      <td></td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.boolean">bool</a></td>
      <td><span class="parametername">throwOnError</span></td>
      <td></td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.componentmodel.itypedescriptorcontext">ITypeDescriptorContext</a></td>
      <td><span class="parametername">context</span></td>
      <td></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="C1.C1Preview.LineDef.html">LineDef</a></td>
      <td></td>
    </tr>
  </tbody>
</table>
</div>
