Erases any data stored in the object that could have been used for a drag and drop operation.
This method concerns the data previously created by the DD_WRITE_DATA method.
Syntax | ||
CALL_METHOD ImageObjectName DD_CANCEL_DATA ReturnCode
|
||
Parameters | ||
NUM_BIN_4 ReturnCode (O) | Return code for the operation. |
|
Possible values for the return code | ||
_ERR_OK | Method run successfully. | |
Conditions for use | None. |
Notes:
- This method is not implemented by the Java generator.
- It is not available in Mobile generation.
Indicates whether any data items in a specified format are available among the data concerned by the current drag and drop operation. The format can be either one predefined in Windows or one defined by the developer.
Syntax | ||
CALL_METHOD ImageObjectName DD_DATA_AVAILABLE Format Availability ReturnCode
|
||
Parameters | ||
ALPHA(50) Format (I) | Name of the data format to be sought. |
|
BOOL Availability (O) | This value is set to *TRUE if any data in the requested format is available. |
|
NUM_BIN_4 ReturnCode (O) | Return code for the operation. |
|
Possible values for the Format parameter | ||
_CF_TEXT | Format for text data items in the ANSI format. |
|
_CF_OEMTEXT | Format for text data items in the OEM format. |
|
_CF_UNICODETEXT | Format for text data items in the UNICODE format. |
|
_CF_DIB | Format for DIB (Device Independent Bitmap) data items. |
|
Any string that does not begin with "CF_" for a format defined by the developer. | ||
Possible return code values | ||
_ERR_OK |
Method run successfully. |
|
_ERR_CTX_USE |
Method used other than as part of an event enabled for it. |
|
_ERR_INVALID_FORMAT |
The specified format name does not match any data or is invalid. |
|
Conditions for use | This method can only be used with the DD_EnterDrag, DD_DragOver and DD_Drop events. |
Notes:
This method is not implemented by the Java generator.
It is not available in Mobile generation.
Initiates a drag and drop operation between a source object and a destination object using the data stored in the source object by the DD_WRITE_DATA method.
The relevant data can be either copied or moved to the destination object.
The set formed by this data is identified by a format name. The format can be either one predefined in Windows or one defined by the developer.
Note: Where a predefined format is used, only the first data item written by the DD_WRITE_DATA method is taken into consideration.
Syntax | ||
CALL_METHOD ImageObjectName DD_EXECUTE_DRAG Format AllowedActions ActionDone ReturnCode |
||
Parameters | ||
ALPHA(50) Format (I) |
Data format name. |
|
NUM_BIN_4 AllowedActions (I) |
Actions permitted in the destination object. |
|
NUM_BIN_4 ActionDone (O) |
Action performed in the destination object. |
|
NUM_BIN_4 ReturnCode (O) |
Return code for the operation. |
|
Possible values for the Format parameter | ||
_CF_TEXT | Format for text data items in the ANSI format. |
|
_CF_OEMTEXT | Format for text data items in the OEM format. |
|
_CF_UNICODETEXT | Format for text data items in the UNICODE format. |
|
_CF_DIB | Format for DIB (Device Independent Bitmap) data items. |
|
Any string that does not begin with "CF_" for a format defined by the developer, and which contains all the written data. | ||
Possible values of the AllowedActions parameter | ||
_DD_ACTION_COPY |
Data can be copied to the destination object. |
|
_DD_ACTION_MOVE |
Data can be moved to the destination object (and deleted from the source object). |
|
_DD_ACTION_COPY_MOVE |
Combination of the above two actions. |
|
Possible values of the ActionDone parameter | ||
_DD_NO_ACTION |
The user released the mouse button over an object that does not accept the data, or cancelled the operation by pressing Escape. |
|
_DD_ACTION_COPY |
The data must be copied to the destination object. |
|
_DD_ACTION_MOVE |
The data must be moved to the destination object (and deleted from the source object). |
|
Possible return code values | ||
_ERR_OK |
Method run successfully. |
|
_ERR_INVALID_PARAM |
One or more parameters have invalid values. |
|
_ERR_CTX_USE |
Method used other than as part of an event enabled for it. |
|
_ERR_NO_DATA |
No data was stored for a drag and drop operation. |
|
_ERR_INVALID_FORMAT |
The specified format name is invalid. |
|
Conditions for use | This method must be used with the DD_BeginDrag event. |
Notes:
- This method is not implemented by the Java generator.
- It is not available in Mobile generation.
Reads the data transferred as part of the current drag and drop operation. This data is in fact a copy of the data written in the source object by the DD_WRITE_DATA method.
This method must be used in a loop to run through all the data for a given Adelia type.
All the data for a given type is read when the number of data items read is less than the number of data items to be read.
Notes:
- Calling this method with an Adelia array containing x elements has the same effect as calling the method x times with an Adelia variable.
- If the DD_WRITE_DATA method has been used to write x records each containing two ALPHA variables, the DD_READ_DATA method must be run twice, with the indexes (2x – 1) and 2x, in order to retrieve the strings in the nth record, or once with the index (2x-1) and an array capable of receiving two data items.
- No distinction is made between packed and extended numerical variables, however long they are and however many decimal places they have. The values of numerical and extended variables may be truncated when they are read. With strings, the read operation will fail if the Adelia variable is too small to contain the string being read.
Syntax | ||
CALL_METHOD ImageObjectName DD_READ_DATA Format AdeliaVar Index DataNumber ReturnCode |
||
Parameters | ||
ALPHA(50) Format (I) |
Name of the data format to be sought. |
|
Possible types for the AdeliaVar parameter (I): ALPHA, DATE, TIME, NUM_E, NUM_P, NUM_BIN_2, NUM_BIN_4, BOOL, TIMESTAMP, IMAGE |
Variable or array filled with data. |
|
NUM_BIN_4 Index (I) |
Index of the data to be read for a given type. |
|
NUM_BIN_4 DataNumber (I/O) |
Number of data items to be added. With variables, this parameter must be 1, and with arrays, less than or equal to the number of elements in the array. Once the method has been called, it contains the number of data items written. |
|
NUM_BIN_4 ReturnCode (O) |
Return code for the operation. |
|
Possible return code values | ||
_ERR_OK |
Method run successfully. |
|
_ERR_CTX_USE |
Method used other than as part of an event enabled for it. |
|
_ERR_INVALID_TYPE |
A variable used in the method is not a suitable Adelia type. |
|
_ERR_INVALID_PARAM |
One or more parameters have invalid values. |
|
_ERR_STRING_LEN |
The data to be read includes a character string longer than the Adelia variable. |
|
_ERR_VAR_NOT_AVAIL |
The data to be read does not contain data of the specified Adelia type. |
|
_ERR_INVALID_FORMAT |
The specified format name does not match any data or is invalid. |
|
Conditions for use | This method can only be used with the DD_EnterDrag, DD_DragOver and DD_Drop events. |
Notes:
- This method is not implemented by the Java generator.
- It is not available in Mobile generation.
Adds data (i.e. the contents of the Adelia variables) to the data to be transferred by a drag and drop operation. This data is stored in the object until the end of the drag and drop operation, and is then deleted automatically.
Notes:
- Calling this method with an array containing x elements has the same effect as calling the method x times with a variable containing the individual array elements.
- No distinction is made between the extended and packed numerical data types.
Syntax | ||
CALL_METHOD ImageObjectName DD_WRITE_DATA AdeliaVar DataNumber ReturnCode |
||
Parameters | ||
Possible types for the AdeliaVar parameter (I): ALPHA, DATE, TIME, NUM_E, NUM_P, NUM_BIN_2, NUM_BIN_4, BOOL, TIMESTAMP, IMAGE
|
Variable or array containing the data. |
|
NUM_BIN_4 DataNumber (I/O) |
Number of data items to be added. With variables, this parameter must be 1, and with arrays, less than or equal to the number of elements in the array. Once the method has been called, it contains the number of data items written. |
|
NUM_BIN_4 ReturnCode (O) |
Return code for the operation. |
|
Possible return code values | ||
_ERR_OK |
Method run successfully. |
|
_ERR_INVALID_TYPE |
A variable used in the method is not a suitable Adelia type. |
|
_ERR_INVALID_PARAM |
One or more parameters have invalid values. |
|
Conditions for use | None. |
Notes:
- This method is not implemented by the Java generator.
- It is not available in Mobile generation.