[dba-Tech] Digital Photo Contact Sheet Generator

Dan Waters dwaters at usinternet.com
Fri Dec 31 13:50:17 CST 2004


Bryan,

This is something else that might work for you.  This is code I use behind a
form - the primary method is Application.FileSearch.  Look through help for
more info.


    Dim fs As Object
    Dim intCount As Integer
    Dim stgPath As String
    Dim stgFile As String
    Dim stgFullPath As String

    Set fs = Application.FileSearch

    With fs
        fs.NewSearch
        fs.LookIn = txtTopFolder.Value
        If Not IsNull(txtFileType) Then
            fs.FileName = "*." & txtFileType
        Else
            fs.FileName = "*.*"
        End If
        fs.FileType = msoFileTypeAllFiles
        fs.SearchSubFolders = True
        DoCmd.Hourglass True
        If fs.Execute() > 0 Then
            DoCmd.SetWarnings False
            For intCount = 1 To fs.FoundFiles.Count
                stgFullPath = fs.FoundFiles(intCount)
                stgFile = Mid(stgFullPath, InStrRev(stgFullPath, "\") + 1)
                stgPath = Left(stgFullPath, InStrRev(stgFullPath, "\"))
                DoCmd.RunSQL "INSERT INTO tblFilesDuplicate (File, Path)
VALUES ('" & stgFile & "', '" & stgPath & "');"
            Next intCount
            DoCmd.SetWarnings True
        Else
            DoCmd.Hourglass False
            FormattedMsgBox GstgReminder, "No files found.@ @", vbOKOnly,
"No Files"
        End If
        DoCmd.Hourglass False
    End With

    Exit Sub


HTH,
Dan Waters
ProMation Systems

-----Original Message-----
From: dba-tech-bounces at databaseadvisors.com
[mailto:dba-tech-bounces at databaseadvisors.com] On Behalf Of Bryan Carbonnell
Sent: Friday, December 31, 2004 10:32 AM
To: Discussion of Hardware and Software issues
Subject: [dba-Tech] Digital Photo Contact Sheet Generator

I am looking for a progam that will scan a folder, and sub-folders,
and create a contact sheet from them.

It also needs to include the full path, or at least, the relative path
and file name of the pic.

All the applications that I have tried so far will give me the file
name, but not the path.

I've got about 600 digital photos that I want to start to get a handle
on, before it gets way out of control.

Thanks

-- 
Bryan Carbonnell - carbonnb at gmail.com
Life's journey is not to arrive at the grave safely in a well
preserved body, but rather to skid in sideways, totally worn out,
shouting "What a great ride!"
_______________________________________________
dba-Tech mailing list
dba-Tech at databaseadvisors.com
http://databaseadvisors.com/mailman/listinfo/dba-tech
Website: http://www.databaseadvisors.com




More information about the dba-Tech mailing list