Spread 8.0 Documentation
SetData Method (fpDataObject)
Support Options
ActiveX Reference > ActiveX Methods > SetData Method (fpDataObject)

Glossary Item Box

SetData Method (fpDataObject)


See Also

Applies To

fpDataObject object

Description

Specifies the format and can provide the data.

Syntax

Visual Basic

fpSpread1.fpDataObject.SetData([Value As Variant], [Format As Variant])

Parameter

The following parameters are available:

Parameter Description
Value Data passed to the fpDataObject
Format Specifies the data format being passed
Use one of the following values:
Value Description
1 - fpCFText Text (string data: .TXT files)
2 - fpCFBitmap Bitmap (picture object: .BMP files)
3 - fpCFMetafile Metafiles (picture object: .WMF files)
8 - fpCFDIB Device-independent bitmap (picture object: .DIB files)
9 - fpCFPalette Color palette (picture object)
14 - fpCFEMetafile Enhanced metafile (picture object: .EMF files)
15 - fpCFFiles List of files
-16639 - fpCFRTF Rich text format (.RTF files)

Remarks

Call the SetData method several times to set multiple formats for the data.

Both of the Value and Format parameters are optional, but at least one must be provided. If the Value parameter is specified but not the Format parameter, then the control will assume you are passing a string value and default to the 1 (fpCFText) format. If the Format parameter is specified but the Value parameter is not, then delayed rendering occurs, that is, format but no data is passed. The source's OLESetData event will then occur and the data type will be provided through the OLESetData event's parameters.

The 15 (fpCFFiles) value uses the Files property of the fpDataObject to retrieve the data.

If you use 2 (fpCFBitmap, 3 (fpCFMetafile), 8 (fpCFDIB), 9 (fpCFPalette), or 14 (fpCFEMetafile), the picture object must have the appropriate type.

You can provide only one piece of data in each format, but you can provide multiple formats.

See Also

Files property

OLESetData, OLEStartDrag events

Clear, GetData, GetFormat methods

© 2002-2014 ComponentOne, a division of GrapeCity. All Rights Reserved.