Using the WinDDE API

With WinDDE support, you can invoke a Windows® application and send or receive data to or from it. To use this functionality, the program must use the Windows front-end.

Before using the DDE functions, the TCP communication channel between the application and the front-end must be established with a display (OPEN WINDOW, MENU, DISPLAY TO).

Figure: The four-part procedure of the DDE API

This figure shows the four-part procedure. The content of the figure is described in the paragraph below.>
The DDE API is used in a four-part procedure, as described in the following steps:
  1. The application sends to the front-end the DDE order using the TCP/IP channel.
  2. The front-end executes the DDE order and sends the data to the Windows application through the DDE API.
  3. The Windows application executes the command and sends the result, which can be data or an error code, to the front-end.
  4. The Windows front-end sends back the result to the application using the TCP/IP channel.

A DDE connection is uniquely identified by two values: the name of the DDE Application, and the document. Most DDE functions require these two values to identify the DDE source or target.