SendObject -
04-22-2009
, 09:47 PM
I am using the SendObject method in Access2007 to email and internet-
fax documents.
I use the SaveAsPDF add-on to create a PDF attachment to send.
I loop through the documents and group by recipient.
If a recipient has more than a couple of pages in the document the
SaveAsPDF process slows down.
The result is that the code keeps looping and sends the currently
processing PDF attachment to the next recipient.
This is a very bad thing.
I have temporarily "solved" the problem by restricting each send to a
single recipient.
Another solution I have tried is putting a 10 second delay loop in my
code to allow the PDF attachment to complete formatting.
I suspect that this PDF attachment is saved as a temporary file by
either Access or my email client.
If I knew where this temp file was saved I could loop to check the
file path until it is deleted then continue the next recipient.
Does anyone know if I'm on the right path and where I might look for
the temp file? |