Skip to main content

DevExpress v24.2 Update — Your Feedback Matters

Our What's New in v24.2 webpage includes product-specific surveys. Your response to our survey questions will help us measure product satisfaction for features released in this major update and help us refine our plans for our next major release.

Take the survey Not interested

TdxCustomSpreadSheet.ActiveSheet Property

Provides access to a generic worksheet object corresponding to the currently active sheet.

#Declaration

Delphi
property ActiveSheet: TdxSpreadSheetCustomView read; write;

#Property Value

Type
TdxSpreadSheetCustomView

#Remarks

You can use this property to:

  • Obtain a generic worksheet object corresponding to the active sheet within a workbook. Since a generic worksheet object does not correspond to any of the actual worksheet types, you need to cast it to the respective type to access the type-specific properties and methods;

  • Activate another sheet within a workbook by assigning its corresponding TdxSpreadSheetCustomView object.

dxSpreadSheet1.ActiveSheet := dxSpreadSheet1.Sheets[2];

In this example, the Sheets property, which provides zero-based indexed access to all generic sheet objects within a workbook, is used as a source of the target worksheet object.

Note

A newly created worksheet becomes active immediately.

To access the currently active Table View worksheet, use its ActiveSheetAsTable property, added as an alternative to the type casting operation.

See Also