A script-enabled browser is required for this page to function properly.

DDE.REQUEST built-in procedure

This procedure requests data from a DDE server application.

Syntax

DDE.REQUEST (convid, item, buffer, dataformat, timeout)

Parameter

Type

Description

convid
PLS_INTEGER

DDE conversion identifier that is returned by DDE.INITIATE.

item
VARCHAR2

Requested data item name.

buffer
VARCHAR2

Return data buffer.

dataformat
PLS_INTEGER

Format of requested data.

timeout
PLS_INTEGER

Timeout duration in milliseconds.

The value of Item depends on what values are supported by the DDE server application on the current conversation topic.

Be aware that the Buffer parameter determines the length of the return string. It is your responsibility to ensure that the return data buffer is large enough for the requested data. If the buffer size is smaller than the requested data, the data is truncated and an error may occur.

Microsoft Windows predefined data formats can be used for DataFormat. A user-defined format that is registered with DDE.GETFORMATNUM can also be used, provided the DDE server application recognizes this format. It is your responsibility to ensure that the DDE server application will process the specified data format.

Timeout specifies the maximum length of time, in milliseconds, that this routine waits for a response from the DDE server application. If you specify an invalid number, such as negative number, then the default value of 1000 ms is used. The duration of the timeout depends on machine configuration and the DDE server application.

Example


DECLARE
   ConvID PLS_INTEGER;
   Buffer CHAR(100);
BEGIN
   /* Open a DDE conversation with Microsoft Excel for Windows on
      topic abc.xls. */
    ConvID := DDE.INITIATE('EXCEL', 'C:\abc.xls');
   /* Request data from 6 cells between row 2, column 2
       and row 3, column 4. */
     DDE.REQUEST(ConvID, 'R2C2:R3C4', Buffer, DDE.CF_TEXT,1000);
END;

See also

About the DDE built-in package

DDE built-in package

DDE built-in exceptions