VCL Spreadsheet Controls: Supported Commands List
- 18 minutes to read
Spreadsheet and Report Designer controls provide a comprehensive set of commands that manage cells and their content, perform general spreadsheet-related operations, invoke various built-in dialogs, etc. To allow users to execute any of these commands, you can link them manually to elements of your UI or employ the automatic Ribbon or Toolbar UI generation feature available in the ExpressSpreadSheet Suite.
You can use most of the supported commands with any control that provides the Action property. However, commands that allow users to enter specific values (i.e., assign a color value, font, etc.) instead of performing simple predefined operations (such as invoking a dialog), are designed to be used with bar item editors, including but not limited to, the TdxRibbonColorGalleryItem, TcxFontNameComboBox, and TcxComboBox components. For detailed information on using such commands with custom UI elements, refer to the full list of commands below and their corresponding action class descriptions.
Core Spreadsheet Commands
A
- AlignHorizontalCenter
- Centers the content horizontally within all selected cells. To apply the other two horizontal cell content alignments, use the AlignHorizontalLeft and AlignHorizontalRight commands.
- AlignHorizontalLeft
- Aligns the content to the left borders of all selected cells. To apply the other two horizontal cell content alignments, use the AlignHorizontalCenter and AlignHorizontalRight commands.
- AlignHorizontalRight
- Aligns the content to the right borders of all selected cells. To apply the other two horizontal cell content alignments, use the AlignHorizontalLeft and AlignHorizontalCenter commands.
- AlignVerticalBottom
- Aligns the content to the bottom borders of all selected cells. To apply the other two vertical cell content alignments, use the AlignVerticalCenter and AlignVerticalTop commands.
- AlignVerticalCenter
- Centers the content vertically within all selected cells. To apply the other two vertical cell content alignments, use the AlignVerticalBottom and AlignVerticalTop commands.
- AlignVerticalTop
- Aligns the content to the top borders of all selected cells. To apply the other two vertical cell content alignments, use the AlignVerticalBottom and AlignVerticalCenter commands.
- AutoFitColumnWidth
- Adjusts the widths of cells (and, therefore, columns) according to their content’s size.
- AutoFitRowHeight
- Adjusts the heights of cells according to their content’s size.
- AutoSumGallery
- Implements the auto sum gallery.
B
- BordersAll
- Assigns the sscbsThin style to all cell borders within all currently selected cell ranges.
- BordersBottom
- Assigns the sscbsThin style to the cell borders matching the bottom boundaries of all currently selected cell ranges. To apply different styles to the same cell borders, use the BordersBottomDouble and BordersBottomThick commands.
- BordersBottomDouble
- Assigns the sscbsDouble style to the cell borders matching the bottom boundaries of all currently selected cell ranges. To apply different styles to the same cell borders, use the BordersBottom and BordersBottomThick commands.
- BordersBottomThick
- Assigns the sscbsThick style to the cell borders matching the bottom boundaries of all current cell selections. To apply different styles to the same cell borders, use the BordersBottom and BordersBottomDouble commands.
- BordersLeft
- Assigns the sscbsThin style to the cell borders matching the left boundaries of all current cell selections.
- BordersMore
- Invokes the Format Cells dialog with the active Border tab for the current cell selection.
- BordersNone
- Restores the default border style for the current cell selection.
- BordersOutside
- Assigns the sscbsThin style to the cell borders matching the perimeters of all current cell selections.
- BordersOutsideThick
- Assigns the sscbsThick style to the cell borders matching the perimeters of all current cell selections.
- BordersRight
- Assigns the sscbsThin style to the cell borders matching the right boundaries of all currently selected cell ranges.
- BordersTop
- Assigns the sscbsThin style to the cell borders matching the top boundaries of all current cell selections.
- BordersTopAndBottom
- Assigns the sscbsThin style to the cell borders matching the top and bottom boundaries of all currently selected cell ranges. To apply different styles to the same cell borders, use the BordersTopAndBottomDouble and BordersTopAndBottomThick commands.
- BordersTopAndBottomDouble
- Assigns the sscbsDouble style to the cell borders matching the top and bottom boundaries of all currently selected cell ranges. To apply different styles to the same borders, use the BordersTopAndBottom and BordersTopAndBottomThick commands.
- BordersTopAndBottomThick
- Assigns the sscbsThick style to the cell borders matching the top and bottom boundaries of all currently selected cell ranges. To apply different styles to the same borders, use the BordersTopAndBottom and BordersTopAndBottomDouble commands.
C
- ChangeFillColor
- Link this command to a TcxColorComboBox or TdxRibbonColorGalleryItem element in a Ribbon or Toolbar UI to allow end-users to set the required color as a background for all selected cells. If you need to use the ChangeFillColor command with a custom control, refer to the TdxSpreadSheetChangeFillColor class description.
- ChangeFontColor
Link this command to a TcxColorComboBox or TdxRibbonColorGalleryItem element in a Ribbon or Toolbar UI to allow end-users to change the font color used to display:
- The values in all selected cells.
- The text selection within an in-place cell editor (only if the rich content formatting functionality is enabled in the Spreadsheet/Report Designer control).
- ChangeFontName
Link this command to a TcxFontNameComboBox item control in a Ribbon or Toolbar UI to allow end-users to change the typeface of the font used to display:
- The values in all selected cells.
- The text selection within an in-place cell editor (only if the rich content formatting functionality is enabled in the Spreadsheet/Report Designer control).
- ChangeFontSize
Link this command to a TcxComboBox item control in a Ribbon or Toolbar UI to allow end-users to change the size of the font used to display:
- The values in all selected cells.
- The text selection within an in-place cell editor (only if the rich content formatting functionality is enabled in the Spreadsheet/Report Designer control).
- ClearAll
- Clears values stored in all currently selected cells and restores their default style settings. To clear cells without affecting their custom style settings, use the ClearContents command. The ClearFormats command restores the default cell style settings without affecting the stored values.
- ClearContents
- Deletes values stored in the selected cells while keeping their custom style settings. To restore the default cell style settings, use the ClearAll or ClearFormats command.
- ClearFormats
- Restores the default style settings for all selected cells without affecting their values. To clear the cell contents, use the ClearAll or ClearContents command.
- ClearPrintArea
- Restores the active worksheet‘s default print area.
- CopySelection
- Copies the currently selected cell/cell range or floating container (including comments) to the clipboard. To paste the clipboard content into the active worksheet, use the PasteSelection command. An end-user can reproduce the CopySelection command’s effect by pressing the Ctrl+C or Ctrl+Insert key combination.
- CompatibilityFormulasGallery
- Implements a gallery with functions from the “Compatibility” category.
- CreateDefinedName
- Invokes the “New Name” dialog.
- CreateDefinedNamesFromSelection
- Invokes the “Create Names from Selection” dialog.
- CutSelection
- Moves the currently selected cell/cell range or floating container (including comments) to the clipboard. To paste the clipboard content into the active worksheet, use the PasteSelection command. An end-user can reproduce the CutSelection command’s effect by pressing the Ctrl+X or Shift+Del key combination.
D
- DateAndTimeFormulasGallery
- Implements a gallery with functions from the “Date and Time” category.
- DecreaseFontSize
Decreases the cell font size by one position within the control’s set of predefined font size values. This command affects the font used to display:
- The values in all selected cells.
- The text selection within an in-place cell editor (only if rich content formatting functionality is enabled in the Spreadsheet/Report Designer control).
Use the ChangeFontSize command to specify the exact font size value instead of using the predefined list.
- DeleteColumns
- Deletes all columns that intersect the current selection area. To delete rows, use the DeleteRows command.
- DeleteComments
- Deletes all comment containers associated with cells within the current selection area. To create new or edit existing cell comments, use the NewComment or EditComment command, respectively.
- DeleteRows
- Deletes all rows that intersect the current selection area. To delete columns, use the DeleteColumns command.
- DeleteSheet
- Removes the active sheet from a spreadsheet document. If the document contains only one visible worksheet, the DeleteSheet command is not available.
E
- EditComment
Invokes the Customize Object dialog with the active Text tab for a comment container whose cell is currently focused. The EditComment command is not available for the cells without associated comment containers. To delete comments, use the DeleteComments command.
A user can reproduce the EditComment command’s effect by pressing the Shift+F2 key combination.
F
- FinancialFormulasGallery
- Implements a gallery populated with functions from the “Financial” category.
- FindAndReplace
- Invokes the Find and Replace dialog. An end-user can reproduce the FindAndReplace command’s effect by pressing the Ctrl+F key combination.
- FreezeFirstColumn
- Immobilizes the leftmost worksheet column in the visible View area. To unlock the frozen column, you can use either the FreezeTopRow or UnfreezePanes command.
- FreezePanes
- Immobilizes a number of left columns and top rows in the active worksheet simultaneously. To unlock frozen columns and rows, use the UnfreezePanes command.
- FreezeTopRow
- Immobilizes the first worksheet row at the top of the visible View area. To unlock the frozen row, you can use either the FreezeFirstColumn or UnfreezePanes command.
G
- GroupColumns
- Groups all columns intersecting the current selection area. If these columns are already grouped, the GroupColumns command creates a nested group. To ungroup columns, use the UngroupColumns command.
- GroupRows
- Groups all rows intersecting the current selection area. If these rows are already grouped, the GroupRows command creates a nested group. To ungroup rows, use the UngroupRows command.
H
- HideColumns
- Hides all columns that intersect the current selection area. To display previously hidden columns, use the UnhideColumns commands. An end-user can reproduce the HideColumns command’s effect by pressing the Ctrl+0 key combination.
- HideRows
- Hides all rows that intersect the current selection area. To display previously hidden rows, use the UnhideRows command. An end-user can reproduce the HideRows command’s effect by pressing the Ctrl+9 key combination.
- HideSheet
- Hides the active worksheet. To display hidden sheets, use the UnhideSheet command. The HideSheet command is not available if the current spreadsheet document has only one visible sheet.
I
- IncreaseFontSize
Increases the font size by one position within the control’s set of predefined font size values. This command affects the font used to display:
- The values in all selected cells.
- The text selection within an in-place cell editor (only if the rich content formatting functionality is enabled in the Spreadsheet/Report Designer control).
Use the ChangeFontSize command to specify the exact font size value instead of using the predefined list.
- InformationFormulasGallery
- Implements a gallery populated with functions from the “Information” category.
- InsertColumns
- Inserts a number of columns matching the absolute width (in cells) of the current selection area. To delete columns, use the DeleteColumns command.
- InsertPageBreak
- Inserts a custom row and/or column page break into the active worksheet according to the focused cell‘s position. Use the ResetAllPageBreaks or RemovePageBreak command to remove all or only a specific custom page break.
- InsertPicture
- Invokes the Insert Picture dialog allowing an end-user to select an image for inserting to a worksheet as the floating picture container.
- InsertRows
- Inserts a number of rows matching the absolute height (in cells) of the current selection area. To delete rows, use the DeleteRows command.
- InsertSheet
- Inserts a new worksheet into the current spreadsheet document and makes it active. To delete sheets, use the DeleteSheet command. An end-user can reproduce the InsertSheet command’s effect by pressing the Shift+F11 key combination.
L
- LogicalFormulasGallery
- Implements a gallery populated with functions from the “Logical” category.
- LookupAndReferenceFormulasGallery
- Implements a gallery populated with functions from the “Lookup and Reference” category.
M
- MathAndTrigFormulasGallery
- Implements a gallery populated with functions from the “Math and Trigonometry” category.
- MergeCells
- Creates merged cells from all currently selected cell ranges. To split a merged cell, use the UnmergeCells command.
- MergeCellsAcross
- Creates merged cells across multiple cells within each individual row that intersects the currently selected cell ranges. To create a merged cell that occupies the entire selected cell range, use the MergeCells and MergeCellsAndCenter commands. The UnmergeCells command splits merged cells into the original worksheet cells.
- MergeCellsAndCenter
- Creates merged cells from all currently selected cell ranges and centers their resulting content horizontally at the bottom. To split a merged cell, use the UnmergeCells command.
- MorePageMargins
- Invokes the “Page Setup” dialog with the active “Margins” tab for the active worksheet. Use the MorePaperSizes or PrintTitles command to display this dialog with the active “Page” or “Sheet” tab, respectively.
- MorePaperSizes
- Invokes the “Page Setup” dialog with the active “Page” tab for the active worksheet. Use the MorePageMargins or PrintTitles command to display this dialog with the active “Margins” or “Sheet” tab, respectively.
N
- NewComment
Creates a new comment container for the focused cell. If the cell already has a comment, the NewComment command is not available. To customize or delete existing comments, use the EditComment or DeleteComments command, respectively.
A user can reproduce the NewComment command’s effect for a non-commented cell by pressing the Shift+F2 key combination.
- NewDocument
- Creates a blank spreadsheet that replaces the current content of the control. To save the current document or open an existing file, use the SaveDocumentAs or OpenDocument commands, respectively.
- NextComment
- Moves focus to the nearest comment container located to the right and/or below the current focus position. To move focus in the opposite direction, use the PreviousComment command.
O
- OpenDocument
- Invokes the Open dialog that allows end-users to load a document file into the Spreadsheet control, replacing the active document. To save the current document to a file or create a blank spreadsheet, use the SaveDocumentAs or NewDocument command, respectively.
P
- PageMarginsGallery
- Implements a gallery populated with page margin options.
- PageOrientationGallery
- Implements a gallery populated with page orientation options.
- PageSizeGallery
- Implements a gallery populated with available paper sizes.
- PasteSelection
- Pastes the current clipboard content (whether it is a bitmap image, floating container, or cell/cell range) into the active worksheet. To copy or cut the cell/cell range or floating container, use the CopySelection or CutSelection commands. An end-user can reproduce the PasteSelection command’s effect by pressing the Ctrl+V or Shift+Insert key combination.
- PreviousComment
- Moves focus to the nearest comment container located to the left and/or above the current focus position. To move focus in the opposite direction, use the NextComment command.
- PrintTitles
- Invokes the “Page Setup” dialog with the active “Sheet” tab for the active worksheet. Use the MorePageMargins or MorePaperSizes command to display this dialog with the active “Margins” or “Page” tab, respectively.
- ProtectSheet
- Enables/disables the active worksheet‘s protection.
- ProtectWorkbook
- Enables/disables the opened spreadsheet document’s protection.
R
- Redo
The Undo and Redo commands allow end-users to employ the Spreadsheet control’s history functionality that can be enabled by setting the OptionsBehavior.History property to True.
Link this command to a UI element to allow end-users to redo actions cancelled by using the Undo command or invoking the Spreadsheet control’s History.Undo procedure. UI elements linked to the Redo command are disabled if there are no undone actions within the currently opened document. An end-user can reproduce the Redo command’s effect by pressing the Ctrl+Y key combination.
- RemovePageBreak
- Removes a custom column and/or row page break immediately to the left of and/or above the focused cell, respectively. Use the ResetAllPageBreaks command to remove all custom page breaks.
- ResetAllPageBreaks
- Removes all custom page breaks from the active worksheet. Use the InsertPageBreak command to create new custom column and row page breaks.
S
- SaveDocumentAs
- Invokes the Save dialog that allows end-users to save the current spreadsheet document to a specified file. To open an existing document file or create a blank spreadsheet, use the OpenDocument or NewDocument command, respectively.
- SetLandscapePageOrientation
- Switches the orientation to landscape for printout pages.
- SetPortraitPageOrientation
- Switches the orientation to portrait for printout pages.
- SetPrintArea
- Sets the current cell selection as the active worksheet‘s custom print area.
- ShowDefinedNameManager
- Invokes the “Name Manager” dialog that allows end users to manage defined names in a spreadsheet document.
- ShowPageSetupForm
- Invokes the Page Setup dialog. Note that the ShowPageSetupForm command requires both the TdxComponentPrinter component and a valid spreadsheet report link.
- ShowPrintForm
- Invokes the Print dialog. Note that the ShowPrintForm command requires both the TdxComponentPrinter component and a valid spreadsheet report link.
- ShowPrintPreviewForm
- Invokes the Print Preview dialog. Note that the ShowPrintPreviewForm command requires both the TdxComponentPrinter component and a valid spreadsheet report link.
- ShowHideComments
- Switches the visibility of all comment containers located in the active worksheet.
- ShowHyperlinkEditor
- Invokes the Insert Hyperlink or Edit Hyperlink dialog depending on the current selection. An end-user can reproduce the ShowHyperlinkEditor command’s effect by pressing the Ctrl+K key combination.
- SortAscending
- Sorts cell data within the current selection area against multiple columns in ascending order. To perform sort operation in descending order, use the SortDescending command.
- SortDescending
- Sorts cell data within the current selection area against multiple columns in descending order. To perform sort operation in ascending order, use the SortAscending command.
- StatisticalFormulasGallery
- Implements a gallery populated with functions from the “Statistical” category.
T
- TextFormulasGallery
- Implements a gallery populated with functions from the “Text” category.
- TextIndentDecrease
- Decreases the horizontal cell text indent by 2 pixels for the current selection. To increase the horizontal indent value, use the TextIndentIncrease command.
- TextIndentIncrease
- Increases the horizontal cell text indent by 2 pixels for the current selection. To decrease the horizontal indent value, use the TextIndentDecrease command.
- ToggleFontBold
Applies/removes the Bold attribute to/from the current font.
If the in-place text formatting functionality is unavailable, the ToggleFontBold command is applicable only to the current cell selection. Otherwise, end-users can execute this command to format text in an in-place cell editor.
Press the Ctrl+B or Ctrl+2 key combination to reproduce the command’s effect.
- ToggleFontItalic
Applies/removes the Italic attribute to/from the current font.
If the in-place text formatting functionality is unavailable, the ToggleFontItalic command is applicable only to the current cell selection. Otherwise, end-users can execute the command to format text in an in-place cell editor.
Press the Ctrl+I or Ctrl+3 key combination to reproduce the command’s effect.
- ToggleFontStrikeout
Applies/removes the Strikeout attribute to/from the current font.
If the in-place text formatting functionality is unavailable, the ToggleFontStrikeout command is applicable only to the current cell selection. Otherwise, end-users can execute the command to format text in an in-place cell editor.
The Ctrl+5 key combination reproduces the command’s effect.
- ToggleFontUnderline
Applies/removes the Underline attribute to/from the current font.
If the in-place text formatting functionality is unavailable, the ToggleFontUnderline command is applicable only to the current cell selection. Otherwise, end-users can execute the command to format text in an in-place cell editor.
Press the Ctrl+U or Ctrl+4 key combination to reproduce the command’s effect.
U
- Undo
The Undo and Redo commands allow end-users to employ the Spreadsheet control’s history functionality that can be enabled by setting the OptionsBehavior.History property to True.
Link this command to a UI element to allow end-users to undo actions performed within the Spreadsheet control. UI elements linked to the Undo command, are disabled if the currently active document is either unmodified or already returned to the original state by using the Undo command or the Spreadsheet control’s History.Undo procedure. An end-user can reproduce the Undo command’s effect by pressing the Ctrl+Z or Alt+Backspace key combination.
- UnfreezePanes
- Unlocks all frozen columns and rows in the active sheet. To freeze columns and/or rows, use the FreezeFirstColumn, FreezeTopRow, and FreezePanes commands.
- UngroupColumns
- Ungroups all columns intersecting the current selection area. To ungroup rows, use the UngroupRows command.
- UngroupRows
- Ungroups all rows intersecting the current selection area. To ungroup columns, use the UngroupColumns command.
- UnhideColumns
- Displays all hidden columns that intersect the current selection area. To hide columns, use the HideColumns command.
- UnhideRows
- Displays all hidden rows that intersect the current selection area. To hide rows, use the HideRows command.
- UnhideSheet
- Invokes the Unhide dialog that allows end-users to display previously hidden sheets.
- UnmergeCells
- Splits all merged cells in the current selection area. To merge cells, you can use the MergeCells, MergeCellsAcross, and MergeCellsAndCenter commands.
- UseDefinedNameInFormula
- Creates a new formula expression from a selected defined name in the document or inserts the defined name into an existing formula expression.
Z
- ZoomDefault
- Restores the default zoom factor value for the active worksheet. To zoom the sheet in or out, use the ZoomIn and ZoomOut commands.
- ZoomIn
- Zooms the active worksheet in by 10%. To zoom the sheet out or restore the default zoom factor, use the ZoomOut or ZoomDefault command, respectively.
- ZoomOut
- Zooms the active worksheet out by 10%. To zoom the sheet in or restore the default zoom factor, use the ZoomIn or ZoomDefault command, respectively.
Report Designer Commands
D
- DataMember
- Associates a dataset with the selected report template section. The DataMember command is only a wrapper for a custom implementation.
- DesignView
- Enables or disables the report template section and placeholder field highlighting.
- DetailLevel
- Creates a nested detail report template section for building master-detail reports.
- DetailSection
- Creates a detail report template section matching the current cell selection.
E
- EditFilter
- Allows an end-user to specify the data filtering settings. The EditFilter command is only a wrapper for a custom implementation.
F
- FooterSection
- Creates the common footer report template section matching the current cell selection.
G
- GroupFooterSection
- Creates a group footer section within a detail report template section.
- GroupHeaderSection
- Creates a group header section within a detail report template section.
H
- HeaderSection
- Creates the common header report template section matching the current cell selection.
- HorizontalOrientation
- Enables the horizontal report orientation mode.
M
- MultipleDocumentsReportMode
- Enables the multiple documents mode, allowing end-users to build master-detail reports on multiple spreadsheet documents.
- MultipleSheetsReportMode
- Enables the multiple sheets mode, allowing end-users to build master-detail reports on multiple sheets within a single spreadsheet document.
R
- ReportPreview
- Builds and displays the report preview based on the current template. The ReportPreview command is only a wrapper for a custom implementation.
- ResetFilter
- Clears the data filtering settings.
- ResetSection
- Deletes a report template section.
S
- SingleSheetReportMode
- Enables the single sheet mode, allowing end-users to build any reports on a single sheet within the destination spreadsheet document.
- SortFields
- The SortFields command is only a wrapper for a custom implementation.
V
- VerticalOrientation
- Enables the vertical report orientation mode.