# C1.C1Preview.C1PrintDocument.GetXpsC1Doc

## Content

<div class="doc-site-dotnet-api-container">



<h1 id="C1_C1Preview_C1PrintDocument_GetXpsC1Doc_" data-uid="C1.C1Preview.C1PrintDocument.GetXpsC1Doc*">GetXpsC1Doc Method
</h1>
<div class="markdown level0 summary"></div>
<div class="markdown level0 conceptual"></div>



<a id="C1_C1Preview_C1PrintDocument_GetXpsC1Doc_" data-uid="C1.C1Preview.C1PrintDocument.GetXpsC1Doc*"></a>
<h4 id="C1_C1Preview_C1PrintDocument_GetXpsC1Doc" data-uid="C1.C1Preview.C1PrintDocument.GetXpsC1Doc">GetXpsC1Doc()</h4>
<div class="markdown level1 summary"><p>Gets the <a class="xref" href="C1.C1Preview.Export.Xps.XpsC1Doc.html">XpsC1Doc</a> object representing the current document.
That object can be used to access the underlying <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.windows.xps.packaging.xpsdocument">XpsDocument</a>,
which in turn can provide the <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.windows.documents.fixeddocumentsequence">FixedDocumentSequence</a>
(via the call to GetFixedDocumentSequence()) that can be assigned to the Document property
of a document viewer.</p>
<p>
Please note that to avoid memory leaks, the XpsC1Doc object returned by this method should be disposed
when you're finished using it and/or the XpsDocument it provides.
</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="declaration">Declaration</h5>
<div class="codewrapper">
  <pre><code class="lang-csharp hljs">public XpsC1Doc GetXpsC1Doc()</code></pre>
</div>
<div class="codewrapper">
  <pre><code class="lang-vbnet hljs">Public Function GetXpsC1Doc() As XpsC1Doc</code></pre>
</div>
<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.Export.Xps.XpsC1Doc.html">XpsC1Doc</a></td>
      <td><p>The <a class="xref" href="C1.C1Preview.Export.Xps.XpsC1Doc.html">XpsC1Doc</a> object representing the current document.</p>
</td>
    </tr>
  </tbody>
</table>
</div>
