I have an A2K app that generates 100+ individual snapshot reports and saves them to a time/date stamped folder. Later, I need to print these snp reports, but doing it one-at-a-time is killing me. I found some code using the filesystemobject that seems to do everything I need to locate and cycle through the files, but I can't figure out how to print them.
Please anyone have any suggestions? code I hve is below. Thanks!
Dim fsoSysObj As FileSystemObject
Dim fdrFolder As Folder
Dim filFile As File
' Return new FileSystemObject
Set fsoSysObj = New FileSystemObject
Dim strPath, nfiles
strPath = RptFolderNameP 'folder name variable
Set fdrFolder = fsoSysObj.GetFolder(strPath)
nfiles = fdrFolder.Files.Count
' Loop through Files collection
For Each filFile In fdrFolder.Files
If Right(filFile, 3) = "snp" Then
REM here is where I want to print the snp report
End If
Next
Please anyone have any suggestions? code I hve is below. Thanks!
Dim fsoSysObj As FileSystemObject
Dim fdrFolder As Folder
Dim filFile As File
' Return new FileSystemObject
Set fsoSysObj = New FileSystemObject
Dim strPath, nfiles
strPath = RptFolderNameP 'folder name variable
Set fdrFolder = fsoSysObj.GetFolder(strPath)
nfiles = fdrFolder.Files.Count
' Loop through Files collection
For Each filFile In fdrFolder.Files
If Right(filFile, 3) = "snp" Then
REM here is where I want to print the snp report
End If
Next