April 2006
Beginner
1114 pages
98h 16m
English
Use the OLEFormat object to get an OleObject from a Shape object. The OLEFormat object has the following members
:
|
|
|
|
|
|
|
|
|
|
|
|
|
|
The following code demonstrates getting OLE objects from the Shapes collection rather than the OleObjects collection:
Sub GetOleObjectFromShapes( )
Dim shp As Shape, ole As OleObject
' Get the object.
For Each shp In ActiveSheet.Shapes
If shp.Type = msoEmbeddedOleObject Then
' Get the OleObject
Set ole = shp.OLEFormat.Object
' Display some information.
Debug.Print ole.progID
End If
Next
End SubRead now
Unlock full access