Macro To Find and Replace A Picture

MikeG

Well-known Member
Joined
Jul 4, 2004
Messages
845
Office Version
  1. 365
  2. 2019
Platform
  1. Windows
I have a workbook with 12 sheets. Each sheet has a picture in it of the company logo. The logo is usually the same size, but can change a bit by sheet.

The logo is usually in a different place in each - e.g. in one sheet it might cover cells E3 to G5, whereas in another sheet it could be D3 to F5.

It never overlaps with any other pictures or charts. However, there are other pictures and charts in other locations in most sheets.

What I would like to do is have a macro that replaces the logo on each sheet with a new company logo. I will always use the same picture for the new logo - I plan to call it "New_Logo".

For each sheet I can tell the macro a cell that is completely covered by the current logo on that sheet.

Could anyone give me the guts of the code to cycle through the sheets, identify and delete the old logos, and put the new one in the same position as the old?

Thanks,

MikeG
 

Excel Facts

Will the fill handle fill 1, 2, 3?
Yes! Type 1 in a cell. Hold down Ctrl while you drag the fill handle.

Forum statistics

Threads
1,203,397
Messages
6,055,165
Members
444,767
Latest member
bryandaniel5

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