Sub Main()
Dim pic As Shape, rngShp As Range, FSO As Object, IPicDisp As IPictureDisp
Dim fileName As String
On Error Resume Next
Set FSO = CreateObject("Scripting.FileSystemObject")
[COLOR=#ff0000]Dim rngTmp As Range[/COLOR]
For Each pic In Sheet4.Shapes
If pic.Type = msoPicture Then
Set rngShp = ShapeRange(pic)
[COLOR=#ff0000]Set rngTmp = Intersect(Sheet4.Columns(11), rngShp)[/COLOR]
[COLOR=#ff0000]If Not rngTmp Is Nothing Then[/COLOR]
fileName = ThisWorkbook.Path & "\" & Sheet4.Cells(rngShp.Row, 14).Value & ".jpg"
If Not FSO.FileExists(fileName) Then
'Set IPicDisp = PictureFromObject(pic, True)
'SavePicture IPicDisp, fileName
fileName = ThisWorkbook.Path & "\" & Sheet4.Cells(rngShp.Row, 14).Value & ".jpg"
End If
[COLOR=#ff0000]End If[/COLOR]
End If
Next
End Sub