OLEObjects Collection Object
Description
A collection of all the OLEObject objects on the specified worksheet. Each OLEObject object represents an ActiveX control or a linked or embedded OLE object.
Using the OLEObjects Collection
Use the OLEObjects method to return the OLEObjects collection. The following example hides all the OLE objects on worksheet one.
Worksheets(1).OLEObjects.Visible = False
Use the Add method to create a new OLE object and add it to the OLEObjects collection. The following example creates a new OLE object representing the bitmap file Arcade.bmp and adds it to worksheet one.
Worksheets(1).OLEObjects.Add FileName:="Arcade.bmp"
The following example creates a new ActiveX control (a list box) and adds it to worksheet one.
Worksheets(1).OLEObjects.Add ClassType:="Forms.ListBox.1"
Properties
Application property, AutoLoad property, Border property, Count property, Creator property, Enabled property, Height property, Interior property, Left property, Locked property, Parent property, Placement property, PrintObject property, Shadow property, ShapeRange property, SourceName property, Top property, Visible property, Width property, ZOrder property.
Methods
Add method (OLEObjects collection), BringToFront method, Copy method, CopyPicture method, Cut method, Delete method, Duplicate method, Item method (OLEObjects collection), Select method, SendToBack method.