UpdateLink Method

Microsoft Excel Visual Basic

UpdateLink Method

       

Updates a Microsoft Excel, DDE, or OLE link (or links).

expression.UpdateLink(Name, Type)

expression   Required. An expression that returns a Workbook object.

Name   Optional String. The name of the Microsoft Excel or DDE/OLE link to be updated, as returned from the LinkSources method.

Type   Optional XlLinkType.

XlReferenceStyle can be one of these XlReferenceStyle constants.
xlLinkTypeExcelLinks default.
xlLinkTypeOLELinks  (also used for DDE links)

Remark

Note  When the UpdateLink method is called without any parameters, Excel defaults to updating all worksheet links.

Example

This example updates all links in the active workbook.

ActiveWorkbook.UpdateLink Name:=ActiveWorkbook.LinkSources