Excel VBA user defined function to find images in folder (match excel names to folder names of images)
<p>Currently i am using a function to match image names from excel sheet to image folder, but i want one more thing... that if i save image and forget to add its name in excel then it should show me that i forget to add name.
for example if i save 3 images in image folder</p>

<pre><code>16095_1.jpg,16095_2.jpg,16095_3.jpg
</code></pre>

<p>and i add image names in excel sheet as </p>

<pre><code>16095_1.jpg,16095_2.jpg
</code></pre>

<p>then it should warn me that i forget one image name in excel cell.</p>

<p>my image name format is - 16095_1.jpg,16095_2.jpg</p>

<p>function i am using is...</p>

<pre><code>Function findimage(Path As String, ImageList As String)
Dim results
Dim x As Long
Dim dc 'double comma
results = Split(ImageList, ",")
If Not Right(Path, 1) = "\" Then Path = Path &amp; "\"
For x = 0 To UBound(results)
results(x) = Len(Dir(Path &amp; results(x))) &gt; 0
Next
dc = InStr(ImageList, ",,")
If dc = 0 Then
findimage = Join(results, ",")
Else
findimage = ("Double_comma")
End If
End Function
</code></pre>