# GrapeCity.Documents.Pdf.Spec.IPdfArrayExt.GetArray

## Content

<div class="doc-site-dotnet-api-container">



<h1 id="GrapeCity_Documents_Pdf_Spec_IPdfArrayExt_GetArray_" data-uid="GrapeCity.Documents.Pdf.Spec.IPdfArrayExt.GetArray*">GetArray Method
</h1>
<div class="markdown level0 summary"></div>
<div class="markdown level0 conceptual"></div>



<a id="GrapeCity_Documents_Pdf_Spec_IPdfArrayExt_GetArray_" data-uid="GrapeCity.Documents.Pdf.Spec.IPdfArrayExt.GetArray*"></a>
<h4 id="GrapeCity_Documents_Pdf_Spec_IPdfArrayExt_GetArray__1_GrapeCity_Documents_Pdf_Spec_IPdfArray_System_Int32_System_Boolean_System_Boolean_System_Boolean_" data-uid="GrapeCity.Documents.Pdf.Spec.IPdfArrayExt.GetArray``1(GrapeCity.Documents.Pdf.Spec.IPdfArray,System.Int32,System.Boolean,System.Boolean,System.Boolean)">GetArray&lt;T&gt;(IPdfArray, int, bool, bool, bool)</h4>
<div class="markdown level1 summary"><p>Gets the array of <code class="typeparamref">T</code> objects at the specified index.
Returns null if the array does not exist or cannot be converted to an array of <code class="typeparamref">T</code>.</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="declaration">Declaration</h5>
<div class="codewrapper">
  <pre><code class="lang-csharp hljs">public static T[] GetArray&lt;T&gt;(this IPdfArray array, int index, bool singleToArray, bool allowNulls, bool addWarning) where T : IPdfObject</code></pre>
</div>
<div class="codewrapper">
  <pre><code class="lang-vbnet hljs">Public Shared Function GetArray(Of T As IPdfObject)(array As IPdfArray, index As Integer, singleToArray As Boolean, allowNulls As Boolean, addWarning As Boolean) As T()</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="GrapeCity.Documents.Pdf.Spec.IPdfArray.html">IPdfArray</a></td>
      <td><span class="parametername">array</span></td>
      <td><p>The current array.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.int32">int</a></td>
      <td><span class="parametername">index</span></td>
      <td><p>The index of the value to get.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.boolean">bool</a></td>
      <td><span class="parametername">singleToArray</span></td>
      <td><p>Indicates whether to convert a single <code class="typeparamref">T</code> value to an array.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.boolean">bool</a></td>
      <td><span class="parametername">allowNulls</span></td>
      <td><p>Indicates whether to handle <a class="xref" href="GrapeCity.Documents.Pdf.Spec.IPdfNull.html">IPdfNull</a> as <a href="https://learn.microsoft.com/dotnet/csharp/language-reference/keywords/null">null</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">addWarning</span></td>
      <td><p>Indicates whether to add a warning to <span class="xref">GrapeCity.Documents.Pdf.GcPdfDocument.ParserLog</span> if errors occur.</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>T[]</td>
      <td><p>The array associated with the specified key, or null.</p>
</td>
    </tr>
  </tbody>
</table>
<h5 class="typeParameters">Type Parameters</h5>
<table class="table table-bordered table-condensed">
  <thead>
    <tr>
      <th>Name</th>
      <th>Description</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td><span class="parametername">T</span></td>
      <td></td>
    </tr>
  </tbody>
</table>
</div>
