[Expand]General Information
[Expand]WinForms Controls
[Collapse]ASP.NET Controls and MVC Extensions
 [Expand]What's Installed
 [Expand]Common Concepts
 [Collapse]ASP.NET WebForms Controls
   Getting Started
  [Collapse]Grid View
   [Expand]Product Information
    Getting Started
    [Expand]Bind to Data
    [Expand]Data Representation Basics
    [Expand]Focus and Navigation
    [Expand]Edit Data
    [Expand]Use Data Summaries
    [Expand]Filter Data
    [Expand]Group Data
    [Expand]Sort Data
     Merge Data Cells
     Save and Restore Client Layout
    [Expand]Format Data
    [Collapse]Master-Detail Relationship
      Master-Detail: Implementation
      Expanding and Collapsing Detail Rows
     Appearance Customization
     GridView Table Layout
    Grid Designer
   [Expand]Visual Elements
   [Expand]Member Tables
  [Expand]Tree List
  [Expand]Card View
  [Expand]Chart Control
  [Expand]Pivot Grid
  [Expand]Rich Text Editor
  [Expand]Site Navigation and Layout
  [Expand]HTML Editor
  [Expand]Vertical Grid
  [Expand]Data Editors
  [Expand]Docking and Popups
  [Expand]File Management
  [Expand]Data and Image Navigation
  [Expand]Multi-Use Site Controls
  [Expand]Spell Checker
  [Expand]Query Builder
 [Expand]ASP.NET MVC Extensions
 [Expand]Redistribution and Deployment
  Get More Help
 [Expand]API Reference
[Expand]ASP.NET Bootstrap Controls
[Expand]ASP.NET Core Bootstrap Controls
[Expand]WPF Controls
[Expand]Xamarin Controls
[Expand]Windows 10 App Controls
[Expand]Office File API
[Expand]Report and Dashboard Server
[Expand]eXpressApp Framework
[Expand]eXpress Persistent Objects
[Expand]CodeRush Classic
[Expand]Cross-Platform Core Libraries
[Expand]Tools and Utilities
 End-User Documentation
View this topic on docs.devexpress.com (Learn more)

Expanding and Collapsing Detail Rows

To access detail data, an end-user must expand a data row by clicking on its expand button.

By default, end-users can expand several master rows simultaneously. This behavior is controlled by the ASPxGridViewDetailSettings.AllowOnlyOneMasterRowExpanded option. If this option is enabled, only one detail row can be displayed at a time.

To display and/or hide detail data in code, use the ASPxGridView.DetailRows property. This property returns the WebDataDetailRows object, whose methods allow you to expand/collapse individual detail rows and all rows simultaneously, obtain the number of visible detail rows, etc.

ASPxGridView provides multiple client methods that allow you to expand and/or collapse detail rows on the client.

Expanded Expanding/Collapsing Individual Detail Rows

Expanded Expanding/Collapsing All Detail Rows

Each time a detail row is expanded or collapsed, the ASPxGridView.DetailsChanged event is raised.

Is this topic helpful?​​​​​​​