Returns the text displayed in the specified column within the focused row.
public string GetFocusedRowCellDisplayText( GridColumn column )
Public Function GetFocusedRowCellDisplayText( column As GridColumn ) As String
A string representing the text displayed within the specified column in the focused row.
Use the GetFocusedRowCellDisplayText method to obtain the textual representation of a specific cell's value. The returned string is formatted as specified by the GridColumn.DisplayFormat property of the column in which the specified cell resides. To obtain the cell's actual value use the ColumnView.GetFocusedRowCellValue method.
If the specified column does not belong to the current view, this method will try to find the column within the current View whose field name matches the field name of the specified column and then its value will be returned. If no such column is found, this method will return an empty string.
If a group row is focused this method also returns an empty string.
The currently focused row is determined by the ColumnView.FocusedRowHandle property.
To get the text displayed within the focused cell, the ColumnView.GetFocusedDisplayText method can be used. The ColumnView.GetRowCellDisplayText method can be used to retrieve the displayed values of any cell in a View.
Detail pattern Views do not contain data and they are never displayed within XtraGrid. So, the GetFocusedRowCellDisplayText member must not be invoked for these Views. The GetFocusedRowCellDisplayText member can only be used with real Views that are displayed within the Grid Control. The real Views with which an end-user interacts at runtime can be accessed using the following methods.
- 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.