# C1.WPF.ReportViewer.C1ReportViewer.LoadDocumentFromString

## Content

<div class="doc-site-dotnet-api-container">



<h1 id="C1_WPF_ReportViewer_C1ReportViewer_LoadDocumentFromString_" data-uid="C1.WPF.ReportViewer.C1ReportViewer.LoadDocumentFromString*">LoadDocumentFromString Method
</h1>
<div class="markdown level0 summary"></div>
<div class="markdown level0 conceptual"></div>



<a id="C1_WPF_ReportViewer_C1ReportViewer_LoadDocumentFromString_" data-uid="C1.WPF.ReportViewer.C1ReportViewer.LoadDocumentFromString*"></a>
<h4 id="C1_WPF_ReportViewer_C1ReportViewer_LoadDocumentFromString_System_String_" data-uid="C1.WPF.ReportViewer.C1ReportViewer.LoadDocumentFromString(System.String)">LoadDocumentFromString(string)</h4>
<div class="markdown level1 summary"><p>Load an HTML document from a <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.string">string</a>.</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="declaration">Declaration</h5>
<div class="codewrapper">
  <pre><code class="lang-csharp hljs">public void LoadDocumentFromString(string htmlString)</code></pre>
</div>
<div class="codewrapper">
  <pre><code class="lang-vbnet hljs">Public Sub LoadDocumentFromString(htmlString 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">htmlString</span></td>
      <td><p>A <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.string">string</a> containing an HTML document.</p>
</td>
    </tr>
  </tbody>
</table>
<h5 id="C1_WPF_ReportViewer_C1ReportViewer_LoadDocumentFromString_System_String__examples">Examples</h5>
<p>The code below loads a simple HTML document into the control:</p>
<pre><code class="lang-csharp">_c1ReportViewer.LoadDocumentFromString("&lt;html&gt;Hello &lt;b&gt;World&lt;/b&gt;!&lt;/html&gt;");</code></pre>

</div>
