Insert pictures as a note with macro

Akos

New Member
Joined
Nov 20, 2023
Messages
7
Office Version
  1. 365
Platform
  1. Windows
Hello, Is there any macro what can insert pictures (jpg; jpeg) into note section in excel?
The best could be that, the macro can insert it into any column's note section (so not just an exact column) and also create the note for the insert.
If there is a macro for this, after the insert process, can I somehow compress the pictures?

I attached an example about what I mean. (Here you can't see but column B also has a note section and the picture there, thats why I need the macro with any column)
example_.jpg
 

Excel Facts

Format cells as time
Select range and press Ctrl+Shift+2 to format cells as time. (Shift 2 is the @ sign).
Hi Akos. I suspect that the lack of replies is because "notes" are actually comments. If you google pictures in comments there's lots of stuff. Here's some sample code...
VBA Code:
With Activesheet.Range("B" & 1)
        .AddComment
        .Comment.Text Text:="Picture Name:" & Chr(10) & ""
        .Comment.ShapeRange.Fill.UserPicture "C:\Users\Owner\Pictures\YourPictureFile.jpg"
End With
HTH. Dave
 
Upvote 0
Hello Dave, thank you for reply, I was not very detailed about what i want. So basically I need a macro to insert pictures in comment to any column from Row2. (if its easier its ok with column "A" but pls tell me what should i modify in the code to make it work on another column)

The pictures are on my desktop here: C:\Users\szaboako\Desktop\Macro test

The pictures named exactly the same as the column value where I need the pictures in the comment. So firstly I think it needs to find the active column's value in the folder then insert the comment with the picture. (jpg/jpeg file)

It could be awesome, if the macro won't find in this folder the value, just simply goes to the next value in the column and continue the insert process
And i dont know if its possible, but I need the pictures compressed in "web" type (150ppi)

I hope you can help me, and sorry but i'm not so expert in macro codes.
 
Upvote 0
Hi Akos. Where are the picture names (sht name, rows and columns)? What kind of pic files ie. JPG, Gif etc. ? Seems like it's possible to load the comments with pics. Do you want all the comments filled at once? I'm not familiar with what pictures compressed in "web" type means or if it can be done. Maybe others will be able to help with that. Dave
 
Upvote 0

Forum statistics

Threads
1,215,278
Messages
6,124,023
Members
449,139
Latest member
sramesh1024

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