Spread 8.0 Documentation
Value Property
Support Options
ActiveX Reference > ActiveX Properties > Value Property

Glossary Item Box

Value Property


See Also    DLL    Example

Applies To

fpSpread control

Description

Sets or returns unformatted data. This property is available at run time only.

Syntax

C++

CString CSpreadSheet::GetValue( );
void CSpreadSheet::SetValue(LPCTSTR value);

Visual Basic

[form.]fpSpread.Value[ = text$]

Remarks

The following table explains the data format to use when setting data using the Value property, and the format returned when returning data using the Value property. 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 TypeEditMultiLine property is set to True, a line-feed character (ASCII 10 or `\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 TypeTextWordWrap property is set to True, a line-feed character (ASCII 10 or `\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.

This setting is applied to the current sheet setting unless you first set the Sheet property to specify the sheet for which you are setting the property. Set the Col and Row properties to specify a cell before using the Value property. If you set the Col or Row property to –1 to set data for multiple cells, the same data is placed in each cell. If you set the Col or Row property to –1 to return data from multiple cells, unless the cells were set with the Col or Row property set to –1, the property does not return a value.

Note: The Value property does not return the text in a column or row header cell unless the cell contains custom text. The property does not return the auto text in the header cells.

The Value property can be used to set or return data in cells, as can the Clip, ClipValue, and Text properties, and the GetFloat, GetInteger, GetText, SetFloat, SetInteger, and SetText methods. Use the Value property to set or return unformatted data in cells. Number values that contain a decimal symbol must use a period regardless of the international settings. For more information about using these properties and methods, see Adding Data and Returning Data. For more information about formatted data, see Formatted and Unformatted Data.

Data Type

String

See Also

Formatted and Unformatted Data
Adding Data
Returning Data
Creating and Customizing a Static Text Cell

CellType, Clip, ClipValue, Sheet, Text, TypeEditMultiLine, TypeTextWordWrap properties

GetFloat, GetInteger, GetText, SetFloat, SetInteger, SetText methods

DLL Correspondence

SSGetValue, SSSetValue, SSSetValueRange functions

Copyright © GrapeCity, inc. All rights reserved.