DDE - perform a complete DDE conversation in a single command

Return to Introduction  Previous page  Next page

DDE({POKE | EXECUTE},service,topic,item[,data][,onErrorLabel:])

$return = DDE(REQUEST,service,topic,item[,onErrorLabel:])


$returnis a variable that receives the result of a REQUEST operation.
POKEsends text  to the DDE server application.
REQUESTrequests text  from the DDE server application.
EXECUTEsends a command to the DDE server application.
serviceis name of the DDE application for this conversation.
topicis name of the DDE topic for this conversation.
itemis the name of the DDE item for this conversation.
datais a string of text to be sent to the DDE server application for a POKE operation.
onErrorLabel:is a label that execution transfers to if an error occurs.


The DDE command is a shorthand command that performs a complete DDE conversation in a single command. It performs the functions of DDEInitiate, one of DDEPoke, DDERequest or DDEExecute, and DDETerminate. Use this command if you want to perform a single DDE function. 


$result = DDE(REQUEST,"EXCEL","Sheet2",R1C1)


Sample Script

' This script starts Microsoft Excel with a test spreadsheet,

' gets the data in row 1 column 1 of the spreadsheet and types it into

' the terminal emulation screen at the current cursor location.


Run("C:\Program Files\Microsoft Office\Office11\excel.exe ""D:\Test.xls""")


$result = DDE(REQUEST,"EXCEL","Sheet2",R1C1)




See Also:






TN3270 Plus is continually being improved. To learn more about the latest enhancements, please review our Version History web page.