Skip to main content

IThreadSafeAccessible.GetFieldValueDisplayText(IThreadSafeField, Int32) Method

Returns the display representation of the specified field value.

Namespace: DevExpress.XtraPivotGrid

Assembly: DevExpress.PivotGrid.v24.1.Core.dll

NuGet Packages: DevExpress.PivotGrid.Core, DevExpress.Win.Navigation

Declaration

string GetFieldValueDisplayText(
    IThreadSafeField field,
    int lastLevelIndex
)

Parameters

Name Type Description
field IThreadSafeField

An object that implements the IThreadSafeField interface. Identifies a field that owns the value whose display representation should be returned.

lastLevelIndex Int32

A zero-based index of a cell in the Data Area that identifies the required field value. Indexes are numbered starting from the left edge for column fields, and from the top edge for row fields.

Returns

Type Description
String

A String that specifies the display representation of the specified field value.

Remarks

The GetFieldValueDisplayText method is in effect only for field values that have already been displayed. Their display text is contained in the pivot grid cache and can be accessed while the background calculations are being performed. For other field values, the GetFieldValueDisplayText method returns null (Nothing in Visual Basic).

The following image shows cell indexes numerating rows (columns are numerated in the same manner):

CellIndexes

In this example, the GetFieldValueDisplayText method will return:

  • “Argentina” for the Country field and cell index equals 0;
  • “Buenos Aires” for the City field and cell index equals 0;
  • “Austria” for the Country field and cell index equals 1;
  • Empty for the City field and cell index equals 1.

To obtain a required field, use the IThreadSafeAccessible.GetFieldByArea and IThreadSafeAccessible.GetFieldsByArea methods.

See Also