SSClipValueIn Function
Applies To
fpSpread DLL control
Description
Loads unformatted data into a column, a row, or a block of cells.
Syntax
BOOL SSClipValueIn(HWND hWnd, SS_COORD Col, SS_COORD Row, SS_COORD Col2, SS_COORD Row2, LPCTSTR Buffer, long BufferLen);
BOOL TSpread::ClipValueIn(SS_COORD Col, SS_COORD Row, SS_COORD Col2, SS_COORD Row2, LPCTSTR Buffer, long BufferLen);
Parameters
The following parameters are available:
Parameter | Description |
hWnd | Window handle of the fpSpread control |
Col | Column number of the upper-left cell of the block |
Row | Row number of the upper-left cell of the block |
Col2 | Column number of the lower-right cell of the block |
Row2 | Row number of the lower-right cell of the block |
Buffer | Pointer to the buffer containing the data to be loaded |
BufferLen | Size (in bytes) of the buffer |
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. To determine the settings you want for the Col, Row, Col2, and Row2 parameters, see Using Column and Row Properties.
Remarks
Use this function to fill a block of cells with data instead of filling each cell separately using the SSSetValue function. If you need to load large amounts of data into the sheet, use the SSClipValueIn function to improve speed.
In tab-delimited data, each data item is separated by a tab character. Each row is separated by a carriage return (<CR>) and linefeed (<LF>).
When adding data, remove all formatting characters in the data. The following table explains the data format to use when setting data. Values in quotation marks (" ") are string values.
Cell Type | Sample Data | Set or Return Data |
---|---|---|
Button | True (Two-state) | "1" |
False (Two-state) | "0" | |
Not set (Two-state; looks False) | "0" | |
Check Box | True | "1" |
False | "0" | |
Grayed | "2" | |
Not set; looks False | "0" | |
Combo Box | Index number of selected item | |
Currency | "$10,000.00" | "10000.00" |
Date | "10/29/2001" | "10292001" When setting, provide date value as "MMDDYYYY". |
Edit | Text string If the SSSetTypeEdit function's Style parameter is set to ES_MULTILINE, a linefeed character ('\n' in C++) can be used to force a line break when setting text. |
|
Number | "10,000.00" | "10000" or "1E4" |
Owner-Drawn | not applicable | |
Percent | "15%" | "0.15" |
PIC | "22-45-76" | "224576" |
Picture | not applicable | |
Scientific | "2.22E+05" | "222222" |
Static Text | Text string If the SSSetTypeStaticText function's TextStyle parameter is set to SS_TEXT_WORDWRAP, a linefeed character ('\n' in C++) can be used to force a line break when setting text. |
|
Time | "11:25:03 pm" | "232503" When setting, provide time value as "HHMMSS" using 24-hour format. |
Call the SSClipIn function to load formatted data into the sheet.
Refer to Formatted and Unformatted Data for more information about formatted versus unformatted data.
Return Value
TRUE if the function completes successfully; FALSE otherwise.
See Also
SSClipIn, SSClipOut, SSClipValueOut, SSSetSheet, SSSetValue functions
ActiveX Correspondence
ClipValue property