Please enable JavaScript to view this site.

ESL Documentation

Invoked in:

Server

Message from Partner:

WM_DDE_REQUEST

Remarks:

This event is invoked in a server as notification that a client is requesting data.  The server should get the item name (DDEGetItemName) and the format (DDEGetFormat) to determine if it can honor the request for this item in this format.

Required Response:

Upon receipt of a request for data, the DDE protocol requires that the server respond as follows.  The server must respond to this event before attempting to transmit another event to the partner.

 

Acknowledgment

Subroutine Called

Message

Positive

(Request can be honored)

DDEDataString

WM_DDE_DATA

Negative

(Request cannot be honored)

DDEAck with

DDE_FACK status flag not set

WM_DDE_ACK with

DDE_FACK status bit cleared

Default Processing

The DDE DLL default processing is to send a negative acknowledgment if the ESL program does not send any acknowledgment.

Available Queries:

DDEGetAppName

DDEGetTopic

DDEGetItemName

DDEGetFormat

DDEGetErrorID

DDEGetStatus

Example:

response to stimulus DDE DDE_REQUEST

   copy eventparam to ConvID_IV

   copy DDEGetItemName (ConvID_IV) to ItemName_SV

   copy DDEGetFormat (ConvID_IV) to Format_SV

   call GetTheData (ItemName_SV, Format_SV, DataString_SV, DidOK_BV)

   if (DidOK_BV) then

   copy (length of DataString_SV) to DataLength_IV

   copy DDESetStatusFlag (0, DDE_FACKREQ) to Status_IV

   copy DDESetStatusFlag (Status_IV, DDE_FRESPONSE) to Status_IV

   call DDEDataString (ConvID_IV, ItemName_SV, DataString_SV, DataLength_IV, Format_SV, Status_IV)

else

   copy 0 to Status_IV  # send a negative ACK

   call DDEAck (ConvID_IV, ItemName_SV, Format_SV, Status_IV)

 end if