Find name of picture

StevenD

Active Member
Joined
Nov 17, 2004
Messages
262
Hi,

I add a picture to a sheet using the .addPicture code. Depending upon what is in a combobox.

This works fine, but I would like to send this picture to the back automatically as I have some text that needs to be in front of it.

Unfortunately I cannot find a name for the picture.

I have found this code using macro recording

Code:
ActiveSheet.Shapes("Picture 1").Select
    Selection.ShapeRange.ZOrder msoSendToBack
Obviously the name of the picture changes each time the combobox changes, so i need some code to find out the name of the picture that i have inserted.
This way I could use the following code
Code:
PictureName=(need code here)
ActiveSheet.Shapes(PictureName).Select
    Selection.ShapeRange.ZOrder msoSendToBack
 

Excel Facts

Excel motto
Not everything I do at work revolves around Excel. Only the fun parts.

Forum statistics

Threads
1,203,046
Messages
6,053,190
Members
444,644
Latest member
keepontruckinc4

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top