613-518-1166 info@zimdatabases.com

ZIM Language Reference

$DDEFunction

< All Topics

Invokes and interacts with DDE services

Syntax

$DDEFunction ( p1, p2, p3, p4, … )

Parameters

p1

return type, longint

p2

command, longint

p3

server handle, longint

p4

application command, string

 

Comments

Where p1, p2, and so on, indicate the desired DDE service and the data required by that service. The first parameter, p1, is entirely for Zim’s benefit and defines the data type of the value returned by the DDE service. The second parameter, p2, determines the desired service and the remaining parameters are used by the DDE service itself.

The first parameter, p1, is dependent on the DDE service you invoke and the application with which you are communicating. When using $DDEFunction, specify p1 in  such way that sufficient space is allocated for the return value. For example, if you use $DDEFunction to invoke a DDE service that returns a long integer result, then the p1 you provide must be of type longint as well. If p1 were of type char 10, $DDEFunction would expect a result value of up to 10 characters in length.

The second parameter, p2, is a number that indicates the DDE service to invoke. The possible values for p2 are shown in the table below. The p2 parameter must be of type longint or int.

 

DDE Service

p2 Value

Description

CONNECT

1

Start a conversation with an application and topic.

POKE

2

Set an item to a value.

DISCONNECT

3

Terminate a conversation.

PEEK

4

Retrieve the value of an Item.

EXECUTE

5

Execute an application.

 

The remaining parameters, p3, p4, and so on, are dependent on the DDE service you invoke and the application with which you are communicating.

 

See Also

About DDE Services

Was this article helpful?
0 out Of 5 Stars
5 Stars 0%
4 Stars 0%
3 Stars 0%
2 Stars 0%
1 Stars 0%
How can we improve this article?
Table of Contents