Advanced PowerBuilder

HomePrevious Lesson: DDE Versus OLE
Next Lesson: Deciding Where To Use DDE Or OLE

Which One To Choose, DDE Or OLE ?

Determining a need for DDE and/or OLE support is perhaps less clear. DDE provides an excellent method of importing live data to an application or exporting live data from it. If two applications want to share and manipulate a piece of data without the direct involvement of the user, DDE is the choice.

If an application wants to include facilities to show data types such as Microsoft Excel graphs or sound files provided by OLE servers, OLE client support should be added. If an application has data-rendering capability useful to other applications, it should become an OLE server.

Let us consider the following example: The live data comes to the application A, has the capability of managing communications and receiving and displaying the data. Application B has the capability of plotting the data into variety of graphs. Application D has the capability of recording audio and playing back. Application C is the word processor.

The customer requirement is to produce a document that gives information about the company, with a graph for the recent stock market data and chairman's speech in audio format. The purpose of this example is to help illustrate how to choose the most appropriate type of communication support to include in an application.

In the case here, we begin with a live data feed attached to a communications port, convert it to a stream of DDE data, and finally end up with a linked OLE object.
HomePrevious Lesson: DDE Versus OLE
Next Lesson: Deciding Where To Use DDE Or OLE