Xerox -05W Printer User Manual


 
13-5
Dynamic Data Exchange
=szAppName|szTopicName!szItemName
Therefore the Topic for the particular instance of TeemTalk under question is given
between the | and the ! characters.
The last piece of information required to establish a permanent data link is the item
name itself. TeemTalk treats the item name as a direct reference to a position on the
display area. Each ItemName refers to a line on the screen and is sent in a string
representation of the screen coordinates (top left is 0,0) followed by the length of the
string. For example: '23,5,8' refers to the area of the screen located at column 24, row
6, and continues for 8 characters.
A typical copy to the clipboard, in the case of a DDE Column Copy, would look like
this:
=tt07w|'TTLK1'!'18,1,8'
=tt07w|'TTLK1'!'18,2,8'
=tt07w|'TTLK1'!'18,3,8'
=tt07w|'TTLK1'!'18,4,8'
=tt07w|'TTLK1'!'18,5,8'
When a potential client application (for example Microsoft Excel) has this
information pasted into its cells, a WM_DDE_INITIATE message is broadcast
using the szAppName and szTopicName fields. All applications that recognize the
two strings (this should be a particular instance of TeemTalk) will reply with a positive
WM_DDE_ACK message, assuming of course that the current TeemTalk document
name matches that of the DDE Topic Name.
Once the client receives the WM_DDE_ACK, it will send a WM_DDE_ADVISE
message to TeemTalk. Depending upon the information provided by the client, within
its ADVISE message's Data block, TeemTalk will then provide updates reflecting any
change to the data using the WM_DDA_DATA message, sending the ItemName as
an identifier to the particular area on the screen that has changed. Either a NULL data
item will be sent, informing the client that the particular piece of information has
changed and allowing it to transmit a WM_DDE_REQUEST message using the
ItemName to get the data from TeemTalk when it wants to (i.e. a Warm link), or the
data will be sent directly (Hot link).
Direct Initiation Of A DDE Link
An application that knows the area of the TeemTalk screen that contains data of
interest to it can directly initiate a DDE link to TeemTalk using the appropriate
szAppname and szTopicName. Data messages can then proceed as described in the
previous section, using szItemName(s) to reflect the area of the screen. This method
is adopted by Excel when a particular spreadsheet that contains these command
strings is recalled or reopened using the File menu. As long as the AppName and
DocName (TopicName) match, then TeemTalk can then start sending fresh updates to
Excel, once the initial (WM_DDE_ADVISE) preamble is successfully completed.