Pictures Collection Object

Description

A collection of all the Picture objects on the specified chart sheet, dialog sheet, or worksheet. This collection includes graphics (bitmaps, metafiles, or images created from some other graphic file) and linked or embedded OLE objects.

Accessors

You add a graphic to a sheet by clicking the Picture command on the Insert menu or by using the Insert method. The following example adds the file ARCADE.BMP as a new graphic on worksheet one. The upper-left corner of the new graphic fits into the upper-left corner of the active cell.


Worksheets(1).Pictures.Insert "arcade.bmp"

Use the Pictures method with an argument to access a single member of the collection or without an argument to access the entire collection at once. The following example deletes all of the pictures on the worksheet named "Sheet1."


Worksheets("sheet1").Pictures.Delete

While the Pictures collection contains OLEObject objects, it is easier to access the OLEObject objects using the OLEObjects collection and the OLEObjects method.

Properties

Application Property, Border Property, Count Property, Creator Property, Enabled Property, Formula Property, Height Property, Interior Property, Left Property, Locked Property, OnAction Property, Parent Property, Placement Property, PrintObject Property, Shadow Property, Top Property, Visible Property, Width Property, ZOrder Property.

Methods

Add Method (Graphic Objects and Controls), BringToFront Method, Copy Method, CopyPicture Method, Cut Method, Delete Method, Duplicate Method, Group Method, Insert Method, Item Method, Paste Method (Pictures Object), Select Method, SendToBack Method.