# C1.WPF.FlexGrid.C1FlexGrid.GetPageImages

## Content

<div class="doc-site-dotnet-api-container">



<h1 id="C1_WPF_FlexGrid_C1FlexGrid_GetPageImages_" data-uid="C1.WPF.FlexGrid.C1FlexGrid.GetPageImages*">GetPageImages Method
</h1>
<div class="markdown level0 summary"></div>
<div class="markdown level0 conceptual"></div>



<a id="C1_WPF_FlexGrid_C1FlexGrid_GetPageImages_" data-uid="C1.WPF.FlexGrid.C1FlexGrid.GetPageImages*"></a>
<h4 id="C1_WPF_FlexGrid_C1FlexGrid_GetPageImages_C1_WPF_FlexGrid_CellRange_C1_WPF_FlexGrid_ScaleMode_System_Windows_Size_System_Int32_" data-uid="C1.WPF.FlexGrid.C1FlexGrid.GetPageImages(C1.WPF.FlexGrid.CellRange,C1.WPF.FlexGrid.ScaleMode,System.Windows.Size,System.Int32)">GetPageImages(CellRange, ScaleMode, Size, int)</h4>
<div class="markdown level1 summary"><p>Gets a list of elements that represent parts of the grid fit for rendering
into pages of a document.</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="declaration">Declaration</h5>
<div class="codewrapper">
  <pre><code class="lang-csharp hljs">public List&lt;FrameworkElement&gt; GetPageImages(CellRange rng, ScaleMode scaleMode, Size pageSize, int maxPages)</code></pre>
</div>
<div class="codewrapper">
  <pre><code class="lang-vbnet hljs">Public Function GetPageImages(rng As CellRange, scaleMode As ScaleMode, pageSize As Size, maxPages As Integer) As List(Of FrameworkElement)</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="C1.WPF.FlexGrid.CellRange.html">CellRange</a></td>
      <td><span class="parametername">rng</span></td>
      <td><p>Range of cells to print.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="C1.WPF.FlexGrid.ScaleMode.html">ScaleMode</a></td>
      <td><span class="parametername">scaleMode</span></td>
      <td><p>How to scale the grid to fit on the pages.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.windows.size">Size</a></td>
      <td><span class="parametername">pageSize</span></td>
      <td><p>Size of the pages in pixels.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.int32">int</a></td>
      <td><span class="parametername">maxPages</span></td>
      <td><p>Maximum number of pages to return.</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="https://learn.microsoft.com/dotnet/api/system.collections.generic.list-1">List</a>&lt;<a class="xref" href="https://learn.microsoft.com/dotnet/api/system.windows.frameworkelement">FrameworkElement</a>&gt;</td>
      <td><p>A list with elements that correspond to the pages.</p>
</td>
    </tr>
  </tbody>
</table>
<h5 id="C1_WPF_FlexGrid_C1FlexGrid_GetPageImages_C1_WPF_FlexGrid_CellRange_C1_WPF_FlexGrid_ScaleMode_System_Windows_Size_System_Int32__remarks">Remarks</h5>
<div class="markdown level1 remarks"><pre><code>&lt;p&gt;The elements returned in the list represent portions of the grid 
</code></pre>
<p>that correspond to individual pages in a document.</p>
<p>The <code class="paramref">scaleMode</code> and <code class="paramref">pageSize</code>
parameters define how many pages are returned and the data contained
in each page.</p>
<p>The elements returned in the list may be rendered directly into
the document (by assigning them to the <b>PageVisual</b> property of the
<b>PrintPage</b> event parameter), or they may be combined with other
elements in a template to provide a letterhead, headers, footers, and
additional document content.</p>
</div>


<a id="C1_WPF_FlexGrid_C1FlexGrid_GetPageImages_" data-uid="C1.WPF.FlexGrid.C1FlexGrid.GetPageImages*"></a>
<h4 id="C1_WPF_FlexGrid_C1FlexGrid_GetPageImages_C1_WPF_FlexGrid_ScaleMode_System_Windows_Size_System_Int32_" data-uid="C1.WPF.FlexGrid.C1FlexGrid.GetPageImages(C1.WPF.FlexGrid.ScaleMode,System.Windows.Size,System.Int32)">GetPageImages(ScaleMode, Size, int)</h4>
<div class="markdown level1 summary"><p>Gets a list of elements that represent parts of the grid fit for rendering
into pages of a document.</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="declaration">Declaration</h5>
<div class="codewrapper">
  <pre><code class="lang-csharp hljs">public List&lt;FrameworkElement&gt; GetPageImages(ScaleMode scaleMode, Size pageSize, int maxPages)</code></pre>
</div>
<div class="codewrapper">
  <pre><code class="lang-vbnet hljs">Public Function GetPageImages(scaleMode As ScaleMode, pageSize As Size, maxPages As Integer) As List(Of FrameworkElement)</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="C1.WPF.FlexGrid.ScaleMode.html">ScaleMode</a></td>
      <td><span class="parametername">scaleMode</span></td>
      <td><p>How to scale the grid to fit on the pages.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.windows.size">Size</a></td>
      <td><span class="parametername">pageSize</span></td>
      <td><p>Size of the pages in pixels.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.int32">int</a></td>
      <td><span class="parametername">maxPages</span></td>
      <td><p>Maximum number of pages to return.</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="https://learn.microsoft.com/dotnet/api/system.collections.generic.list-1">List</a>&lt;<a class="xref" href="https://learn.microsoft.com/dotnet/api/system.windows.frameworkelement">FrameworkElement</a>&gt;</td>
      <td><p>A list with elements that correspond to the pages.</p>
</td>
    </tr>
  </tbody>
</table>
<h5 id="C1_WPF_FlexGrid_C1FlexGrid_GetPageImages_C1_WPF_FlexGrid_ScaleMode_System_Windows_Size_System_Int32__remarks">Remarks</h5>
<div class="markdown level1 remarks"><pre><code>&lt;p&gt;The elements returned in the list represent portions of the grid 
</code></pre>
<p>that correspond to individual pages in a document.</p>
<p>The <code class="paramref">scaleMode</code> and <code class="paramref">pageSize</code>
parameters define how many pages are returned and the data contained
in each page.</p>
<p>The elements returned in the list may be rendered directly into
the document (by assigning them to the <b>PageVisual</b> property of the
<b>PrintPage</b> event parameter), or they may be combined with other
elements in a template to provide a letterhead, headers, footers, and
additional document content.</p>
</div>
</div>
