Skip to content

Latest commit

 

History

History
56 lines (36 loc) · 1.39 KB

Excel.Application.DDERequest.md

File metadata and controls

56 lines (36 loc) · 1.39 KB
title keywords f1_keywords api_name ms.assetid ms.date ms.localizationpriority
Application.DDERequest method (Excel)
vbaxl10.chm183093
vbaxl10.chm183093
Excel.Application.DDERequest
822ef77e-5f11-aced-f770-05175ce128c7
04/04/2019
medium

Application.DDERequest method (Excel)

Requests information from the specified application. This method always returns an array.

Syntax

expression.DDERequest (Channel, Item)

expression A variable that represents an Application object.

Parameters

Name Required/Optional Data type Description
Channel Required Long The channel number returned by the DDEInitiate method.
Item Required String The item to be requested.

Return value

Variant

Example

This example opens a channel to the System topic in Word, and then uses the Topics item to return a list of all open documents. The list is returned in column A on Sheet1.

channelNumber = Application.DDEInitiate( _ 
 app:="WinWord", _ 
 topic:="System") 
returnList = Application.DDERequest(channelNumber, "Topics") 
For i = LBound(returnList) To UBound(returnList) 
 Worksheets("Sheet1").Cells(i, 1).Formula = returnList(i) 
Next i 
Application.DDETerminate channelNumber

[!includeSupport and feedback]