SSGetOperationMode, SSSetOperationMode Functions
Applies To
fpSpread DLL control
Description
Set or return the operation mode of the sheet.
Syntax
WORD SSGetOperationMode(HWND hWnd);
WORD SSSetOperationMode(HWND hWnd, WORD wMode);
WORD TSpread::GetOperationMode( );
WORD TSpread::SetOperationMode(WORD wMode);
Parameters
The SSGetOperationMode function has the following parameter:
Parameter | Description |
hWnd | Window handle of the fpSpread control |
The SSSetOperationMode function has the following parameters:
Parameter | Description | |
---|---|---|
hWnd | Window handle of the fpSpread control | |
wMode | Mode of operation Use one of the following values: |
|
Constant | Description | |
SS_OPMODE_NORMAL | Default fpSpread control mode | |
SS_OPMODE_READONLY | Cells, rows, and columns cannot receive focus | |
SS_OPMODE_ROWMODE | Clicking moves focus to a single row (the user can double-click a cell to move focus to that cell) | |
SS_OPMODE_SINGLESEL | Clicking selects a single row (The user cannot select multiple rows or move focus to a cell. One and only one row is selected at all times.) |
|
SS_OPMODE_MULTISEL | Clicking selects a single row; the user can click to select additional rows (Click a selected row to deselect it.) |
|
SS_OPMODE_EXTSEL | Clicking selects a single row; the user can press Ctrl and click to select additional rows, or press Shift and click to select a range of rows (Press Ctrl and click a selected row to deselect it.) |
Remarks
This function is applied to the current sheet setting unless you first call the SSSetSheet function to specify the sheet for which you are calling this function.
Do not use multiple-selection (SS_OPMODE_MULTISEL) or extended-selection (SS_OPMODE_EXTSEL) operation mode when the fpSpread control is in virtual mode (when the SSSetBool SSB_VIRTUALMODE option is TRUE).
When the SSSetOperationMode function wMode parameter is SS_OPMODE_ROWMODE, the SSSetButtonDrawMode function is ignored. While the highlight bar is visible, no buttons are drawn. While the row is being edited, all the buttons in the current row are drawn.
When the SSSetOperationMode function wMode parameter is set to SS_OPMODE_ROWMODE, if you set the SSSetBool function's SSB_ALLOWDRAGDROP boolean to TRUE and you drag and drop a cell or block of cells, the entire row or rows containing the selected cell or block of cells are dragged and dropped.
Return Value
Previous operation mode (one of the values listed for the wMode parameter).
See Also
SSSetBool, SSSetButtonDrawMode, SSSetSheet functions
ActiveX Correspondence
OperationMode property