Back to Devexpress

RowProperties.GetTextCaption() Method

windowsforms-devexpress-dot-xtraverticalgrid-dot-rows-dot-rowproperties-dba6ab61.md

latest2.1 KB
Original Source

RowProperties.GetTextCaption() Method

Gets the row caption display text.

Namespace : DevExpress.XtraVerticalGrid.Rows

Assembly : DevExpress.XtraVerticalGrid.v25.2.dll

NuGet Packages : DevExpress.Win.Navigation, DevExpress.Win.VerticalGrid

Declaration

csharp
public string GetTextCaption()
vb
Public Function GetTextCaption As String

Returns

TypeDescription
String

The row caption display text.

|

Remarks

You can specify a row caption as follows:

The Caption property has priority over Data Annotation Attributes. If neither this property nor a Data Annotation Attribute is specified, the row caption is generated based on the RowProperties.FieldName property value.

Use the GetTextCaption method to obtain the displayed row caption:

csharp
using DevExpress.XtraVerticalGrid;
// ...
if (vGridControl1.FocusedRow.Properties.GetTextCaption() == "ID")
  return;
vb
Imports DevExpress.XtraVerticalGrid
' ...
If vGridControl1.FocusedRow.Properties.GetTextCaption() = "ID" Then
    Return
End If

See Also

RowProperties Class

RowProperties Members

DevExpress.XtraVerticalGrid.Rows Namespace