Determines which of the master row’s details is currently visible.
NuGet Package: DevExpress.Win.Grid
public int GetVisibleDetailRelationIndex( int rowHandle )
Public Function GetVisibleDetailRelationIndex( rowHandle As Integer ) As Integer
An integer value specifying the master row’s handle.
A zero-based integer identifying the opened detail. -1 if the master row is collapsed (i.e. none of the detail Views are visible).
You can expand a master row and make a particular detail visible using the GridView.SetMasterRowExpandedEx method. If you need to access the currently visible detail, use the GridView.GetVisibleDetailView method. To obtain arbitrary details, use the GridView.GetDetailView method instead.
Please refer to the Master-Detail Relationships and Working with Master-Detail Relationships in Code topics for additional information.
Detail pattern Views do not contain data and they are never displayed within XtraGrid. So, the GetVisibleDetailRelationIndex member must not be invoked for these Views. The GetVisibleDetailRelationIndex member can only be used with Views that display real data within the Grid Control. Use the following methods to access these Views with which an end user interacts at runtime.
- GridControl.MainView - returns the top most View in a grid;
- GridControl.FocusedView - returns the focused View;
- GridControl.DefaultView - returns the currently maximized View;
- the sender parameter of View specific events;
- GridView.GetDetailView - returns a detail clone View for a specific master row.