Log In
Home
Support
Demos
Documentation
Blogs
Training
Webinars
[Expand]General Information
[Collapse]WinForms Controls
  Prerequisites
 [Expand]What's Installed
 [Expand]Build an Application
 [Collapse]Controls and Libraries
  [Expand]Forms and User Controls
  [Expand]Messages, Notifications and Dialogs
  [Expand]Editors and Simple Controls
  [Expand]Ribbon, Bars and Menu
  [Expand]Application UI Manager
  [Expand]Docking Library
  [Collapse]Data Grid
   [Expand]Getting Started
   [Expand]Binding to Data
   [Collapse]Grid View
    [Expand]Columns and Card Fields
    [Expand]Rows and Cards
    [Expand]Row, Column and Cell Access API
    [Expand]Split Presentation
    [Expand]Cell Merging
    [Collapse]Row Preview Sections
      Preview Overview
      Tutorial: Customize Row Preview Sections
      Tutorial: Row Preview Sections
      Custom Preview Text
    [Expand]Scrolling
   [Expand]View Technology
   [Expand]Grouping
   [Expand]Sorting
   [Expand]Summaries
   [Expand]Data Editing
   [Expand]Filtering and Locating Rows
   [Expand]Focus and Selection Handling
   [Expand]Processing Rows
   [Expand]Formatting Cell Values
   [Expand]Master-Detail Relationships
   [Expand]Asynchronous Image Load
   [Expand]Export and Printing
   [Expand]Appearance and Conditional Formatting
   [Expand]Batch Modifications
   [Expand]Hit Information
   [Expand]Hints
   [Expand]Popup Menus
   [Expand]Saving and Restoring Layouts
   [Expand]Visual Elements
   [Expand]Design-Time Features
   [Expand]Examples
   [Expand]End-User Capabilities
    Included Components
  [Expand]Vertical Grid
  [Expand]Pivot Grid
  [Expand]Tree List
  [Expand]Chart Control
  [Expand]Diagrams
  [Expand]Gauges
  [Expand]Map Control
  [Expand]Scheduler
  [Expand]Spreadsheet
  [Expand]Rich Text Editor
  [Expand]Spell Checker
  [Expand]Form Layout Managers
  [Expand]Navigation Controls
  [Expand]Printing-Exporting
  [Expand]PDF Viewer
   Reporting
  [Expand]Snap
  [Expand]TreeMap Control
 [Expand]Common Features
  Get More Help
 [Expand]API Reference
[Expand]ASP.NET Controls and MVC Extensions
[Expand]ASP.NET Bootstrap Controls
[Expand]WPF Controls
[Expand]Xamarin Controls
[Expand]Windows 10 App Controls
[Expand]Document Server
[Expand]Reporting
[Expand]Report Server
[Expand]Dashboard
[Expand]eXpressApp Framework
[Expand]CodeRush
[Expand]Cross-Platform Core Libraries
[Expand]Tools and Utilities
 End-User Documentation

Preview Overview

Expanded Online Video

Learn how to enable the row preview sections, manually change their height and text indents, and how to enable automatic height calculation so that text is completely displayed without being truncated.

Expanded Preview Overview

Grid Control provides a preview feature, which allows each row to display a read-only preview section. The preview section is a suitable place to display memo fields or custom data for a given record. Since the preview section is displayed across all columns of the View, the preview section's width is equal to the total column width.

Preview sections are enabled by setting the GridOptionsView.ShowPreview option to true. Preview sections are empty by default. Assign a field from the database to the GridView.PreviewFieldName property to fill them with text data. You can also handle the GridView.CalcPreviewText event to supply custom text to preview sections or to modify the text provided by the PreviewFieldName field.

Note

If the Row Auto-Height or Preview Sections feature is enabled, pixel-based vertical row scrolling is not in effect. See GridOptionsBehavior.AllowPixelScrolling to learn more.

The height of a preview section (in text lines) is specified by the GridView.PreviewLineCount property. The number of text lines can also be calculated automatically depending on their content if the GridOptionsView.AutoCalcPreviewLineCount option is enabled. It is also possible to specify a custom height for individual preview sections via the GridView.MeasurePreviewHeight event.

The text in preview sections has an indent that can be changed via the GridView.PreviewIndent property.

To learn how to customize preview sections in code, refer to the Custom Preview Text topic.

Expanded See Also

How would you rate this topic?​​​​​​​