Sub Img_in_Commentbox() With Application.FileDialog(msoFileDialogFilePicker) .AllowMultiSelect = False 'Only one file .InitialFileName = CurDir 'directory to open the window .Filters.Clear 'Cancel the filter .Filters.Add Description:="Images", Extensions:="*.jpg", Position:=1 .Title = "Choose image" If .Show = -1 Then TheFile = .SelectedItems(1) Else TheFile = 0 End With 'No file selected If TheFile = 0 Then MsgBox ("No image selected") Exit Sub End If Range("A1").AddComment Range("A1").Comment.Visible = True [A1].Comment.Shape.Fill.UserPicture TheFile End Sub
DON'T MISS