ActivateAs Method Example

This example sets the first floating shape on the active document to open in Microsoft Excel, and then it activates the shape. For the example to work, this shape must be an OLE object that can be opened in Microsoft Excel.

With ActiveDocument.Shapes(1).OLEFormat
    .ActivateAs ClassType:="Excel.Sheet"
    .Activate
End With