# GrapeCity.Documents.Pdf.Annotations.Model3DAnnotation.Set3DContent

## Content

<div class="doc-site-dotnet-api-container">



<h1 id="GrapeCity_Documents_Pdf_Annotations_Model3DAnnotation_Set3DContent_" data-uid="GrapeCity.Documents.Pdf.Annotations.Model3DAnnotation.Set3DContent*">Set3DContent Method
</h1>
<div class="markdown level0 summary"></div>
<div class="markdown level0 conceptual"></div>



<a id="GrapeCity_Documents_Pdf_Annotations_Model3DAnnotation_Set3DContent_" data-uid="GrapeCity.Documents.Pdf.Annotations.Model3DAnnotation.Set3DContent*"></a>
<h4 id="GrapeCity_Documents_Pdf_Annotations_Model3DAnnotation_Set3DContent_System_IO_Stream_GrapeCity_Documents_Pdf_Spec_IPdfName_" data-uid="GrapeCity.Documents.Pdf.Annotations.Model3DAnnotation.Set3DContent(System.IO.Stream,GrapeCity.Documents.Pdf.Spec.IPdfName)">Set3DContent(Stream, IPdfName)</h4>
<div class="markdown level1 summary"><p>Sets the 3D stream content for this annotation.</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="declaration">Declaration</h5>
<div class="codewrapper">
  <pre><code class="lang-csharp hljs">public void Set3DContent(Stream stream, IPdfName format)</code></pre>
</div>
<div class="codewrapper">
  <pre><code class="lang-vbnet hljs">Public Sub Set3DContent(stream As Stream, format As IPdfName)</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.io.stream">Stream</a></td>
      <td><span class="parametername">stream</span></td>
      <td><p>The <a class="xref" href="GrapeCity.Documents.Pdf.Annotations.Model3DAnnotation.Stream.html#GrapeCity_Documents_Pdf_Annotations_Model3DAnnotation_Stream">Stream</a> object containing the 3D model data.
Common formats include U3D (Universal 3D) and PRC (Product Representation Compact).</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="GrapeCity.Documents.Pdf.Spec.IPdfName.html">IPdfName</a></td>
      <td><span class="parametername">format</span></td>
      <td><p>The <a class="xref" href="GrapeCity.Documents.Pdf.Spec.IPdfName.html">IPdfName</a> object specifying the format of the 3D data.
Use values from the <a class="xref" href="GrapeCity.Documents.Pdf.Annotations.Model3DStreamFormat.html">Model3DStreamFormat</a> static class (e.g., <a class="xref" href="GrapeCity.Documents.Pdf.Annotations.Model3DStreamFormat.U3D.html#GrapeCity_Documents_Pdf_Annotations_Model3DStreamFormat_U3D">U3D</a> or <a class="xref" href="GrapeCity.Documents.Pdf.Annotations.Model3DStreamFormat.PRC.html#GrapeCity_Documents_Pdf_Annotations_Model3DStreamFormat_PRC">PRC</a>).</p>
</td>
    </tr>
  </tbody>
</table>
<h5 id="GrapeCity_Documents_Pdf_Annotations_Model3DAnnotation_Set3DContent_System_IO_Stream_GrapeCity_Documents_Pdf_Spec_IPdfName__remarks">Remarks</h5>
<div class="markdown level1 remarks"><p>This method creates a new <a class="xref" href="GrapeCity.Documents.Pdf.Annotations.Model3DStream.html">Model3DStream</a> with the provided stream data and format,
replacing any existing 3D stream in the annotation.</p>
</div>
<h5 class="exceptions">Exceptions</h5>
<table class="table table-bordered table-condensed">
  <thead>
    <tr>
      <th>Type</th>
      <th>Condition</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.argumentnullexception">ArgumentNullException</a></td>
      <td><p>Thrown when <code class="paramref">stream</code> is <code>null</code>.</p>
</td>
    </tr>
  </tbody>
</table>
</div>
