# GrapeCity.ActiveReports.Viewer.Win.Viewer.PreviewPages

## Content

<div class="doc-site-dotnet-api-container">



<h1 id="GrapeCity_ActiveReports_Viewer_Win_Viewer_PreviewPages_" data-uid="GrapeCity.ActiveReports.Viewer.Win.Viewer.PreviewPages*">PreviewPages Property
</h1>
<div class="markdown level0 summary"></div>
<div class="markdown level0 conceptual"></div>



<a id="GrapeCity_ActiveReports_Viewer_Win_Viewer_PreviewPages_" data-uid="GrapeCity.ActiveReports.Viewer.Win.Viewer.PreviewPages*"></a>
<h4 id="GrapeCity_ActiveReports_Viewer_Win_Viewer_PreviewPages" data-uid="GrapeCity.ActiveReports.Viewer.Win.Viewer.PreviewPages">PreviewPages</h4>
<div class="markdown level1 summary"><p>Gets or sets the number of pages to preview when loading a report.
Setting this property to a value less than or equal to 0 will result in all pages being loaded and available for preview.</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="declaration">Declaration</h5>
<div class="codewrapper">
  <pre><code class="lang-csharp hljs">[Browsable(false)]
public int PreviewPages { get; set; }</code></pre>
</div>
<h5 class="propertyValue">Property Value</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.int32">int</a></td>
      <td><p>The number of pages to preview. A value less than or equal to 0 indicates that all pages of the report should be loaded and available for preview.</p>
</td>
    </tr>
  </tbody>
</table>
<h5 id="GrapeCity_ActiveReports_Viewer_Win_Viewer_PreviewPages_remarks">Remarks</h5>
<div class="markdown level1 remarks"><p>This property is particularly useful for improving the performance of report loading and rendering in scenarios where only a subset
of the report's pages needs to be previewed initially. It is applicable when loading reports from instances of <a class="xref" href="../MESCIUS.ActiveReports/GrapeCity.ActiveReports.SectionReport.html">SectionReport</a> or <a class="xref" href="../MESCIUS.ActiveReports/GrapeCity.ActiveReports.Document.PageDocument.html">PageDocument</a>.
When a report is loaded with a specific number of preview pages set, only those pages will be available for preview in the viewer.
This can significantly reduce the time and resources required to load and display large reports.</p>
</div>
<h5 id="GrapeCity_ActiveReports_Viewer_Win_Viewer_PreviewPages_examples">Examples</h5>
<p>This example shows how to set the PreviewPages property programmatically in a WinForms application that uses the Viewer control.</p>
<pre><code class="lang-csharp">viewer.PreviewPages = 10;</code></pre>

</div>
