S
Sheila Jipping
I have a function that reads a list, based on the entries list prints an
Access report, and then prints a corresponding .pdf report based on the
entry. The function works except that the Access reports sometimes "beats"
the .pdf report. So instead having report, .pdf, report, .pdf, etc. I'll
end up with report, .pdf, report, .pdf, report, report, .pdf - often it
happens on the third loop but the fact that it happens at all is very
bothersome and throwing a huge monkey wrench into what I am trying to
accomplish.
Below is the loop code.....
Set qdf = CurrentDb.QueryDefs![MtoPrint]
qdf.Parameters![Enter MO number] = rst!MOnum
qdf.Execute
stDocName = "repMoo"
DoCmd.OpenReport stDocName, acViewNormal
pdfFile = rst!PrintNum
strShell = """C:\Program Files\Adobe\Acrobat 7.0\Reader\AcroRd32.exe"" "
& "/p /h " & pdfFile
Shell strShell, vbHide
Access report, and then prints a corresponding .pdf report based on the
entry. The function works except that the Access reports sometimes "beats"
the .pdf report. So instead having report, .pdf, report, .pdf, etc. I'll
end up with report, .pdf, report, .pdf, report, report, .pdf - often it
happens on the third loop but the fact that it happens at all is very
bothersome and throwing a huge monkey wrench into what I am trying to
accomplish.
Below is the loop code.....
Set qdf = CurrentDb.QueryDefs![MtoPrint]
qdf.Parameters![Enter MO number] = rst!MOnum
qdf.Execute
stDocName = "repMoo"
DoCmd.OpenReport stDocName, acViewNormal
pdfFile = rst!PrintNum
strShell = """C:\Program Files\Adobe\Acrobat 7.0\Reader\AcroRd32.exe"" "
& "/p /h " & pdfFile
Shell strShell, vbHide