nikhil goel
nikhil goel

Reputation: 101

Adding a background image to a particular cell

I tried to insert the background image using following code:

Pic = "C://Picture/Logo1"
Activesheet.SetBackgroundPicture Pic

This inserts the picture to full sheet but I want to add it to particular cell or a range of cells. Please help

Upvotes: 1

Views: 3901

Answers (1)

Kiril Lukiyan
Kiril Lukiyan

Reputation: 187

As far as I know excel doesn't support appending the image to a cell (with or without VBA). The background of a single cell supports colors/gradients/fill-patters, but not the pictures. It is possible however, to "place" the picture (shape) object with the same width and height right above the cell and make it locked and move around together with the cell if somebody attempts to resize cell widths. I personally wouldn't go that way, too much to code and too much risk of breaking the structure.

Upvotes: 3

Related Questions