DDEGETDATA

Purpose:

Retrieves a series item from a DDE conversation.

Syntax:

DDEGETDATA(chan, datatype, "item")

chan

-

An integer, the DDE channel number returned by DDEINITIATE.

datatype

-

Optional. An integer or name specifying the type of data to retrieve. Defaults to 0, ASCII. The following are valid data types:

Name

Code

Data Type

Range

ASCII

0

Comma/Space delimited data

N/A

SBYTE

1

Signed Byte

-128 to +127

UBYTE

2

Unsigned Byte

0 to 255

BYTE

2

(same as UBYTE)

0 to 255

SINT

3

Signed Integer

-32768 to +32767

UINT

4

Unsigned Integer

0 to 65536

LONG

5

4-byte Signed Integer

-2,147,483,648 to +2,147,483,647

FLOAT

6

4-byte Floating Point

-10^37 to +10^38

DOUBLE

7

8-byte Floating Point

-10^307 to +10^308

"item"

-

A string, the item to retrieve.

Returns:

A series representing the value of the requested item.

Example:

chan = ddeinit("Excel", "Sheet1")

ddegetdata(chan, "R1C1:R100C1")

ddeterm(CHAN)

 

establishes a DDE conversation with Excel, returns the value of the cells in row 1, column 1 through row 100 column 1 as a series in the current window and then terminates the conversation.

Remarks:

DDEGETDATA always returns a series. Use DDEREQUEST to obtain a string.

See Also:

DDEADVISE

DDEEXECUTE

DDELINK

DDEPOKE

DDEREQUEST

DDESTATUS