G
Guest
I am using Windows XP Pro, and Access 2000, SR-1
I have code that is designed to use the SendObject to send an email with and
Excel attachment. Immediately following this action is code to check the
value of a group and if the first option is selected, send a second email
with another Excel attachment. When this code is run the first email is sent
as expected but even with the option group returning the value of 1, as
designed, the code run but no email is sent and a variety of strange errors
are returned. "Runtime error 2958. Reserved Error" or "Runtime error 2004.
There is not enough memory to perform this opteation. Close unneeded programs
and try the opereation again."
I have to close the database completely in order to get the SendObject to
send another email. If I step through the code and skip the first SendObject
and move to the If statement and the SendObject within it, That emal is sent,
but it will not do both.
Below is the code for this operation:
DoCmd.SendObject acSendReport, _
"rptAllInvoicesDue-WomenswearToExcel", acFormatXLS, _
"John Doe", , , "Invoices Due", _
"Attahced is the latest list of Invoices Due.", 0
DoEvents
If Me.grpIncludeSummary = 1 Then
DoCmd.SendObject acSendReport,
_"rptWomenswearInvoicesDueByWkByCustToExcel", _
acFormatXLS, "Byron Polk", , , _
"Summary of Womenswear Invoices Due", _
"Attahced is the latest list of Womenswear Invoices
Due.", 0
End If
This issue seems to be something related to the SendObject not being
released or completed, but I just cannot find any solution.
Any assistance is apprecitate.
Mr B
I have code that is designed to use the SendObject to send an email with and
Excel attachment. Immediately following this action is code to check the
value of a group and if the first option is selected, send a second email
with another Excel attachment. When this code is run the first email is sent
as expected but even with the option group returning the value of 1, as
designed, the code run but no email is sent and a variety of strange errors
are returned. "Runtime error 2958. Reserved Error" or "Runtime error 2004.
There is not enough memory to perform this opteation. Close unneeded programs
and try the opereation again."
I have to close the database completely in order to get the SendObject to
send another email. If I step through the code and skip the first SendObject
and move to the If statement and the SendObject within it, That emal is sent,
but it will not do both.
Below is the code for this operation:
DoCmd.SendObject acSendReport, _
"rptAllInvoicesDue-WomenswearToExcel", acFormatXLS, _
"John Doe", , , "Invoices Due", _
"Attahced is the latest list of Invoices Due.", 0
DoEvents
If Me.grpIncludeSummary = 1 Then
DoCmd.SendObject acSendReport,
_"rptWomenswearInvoicesDueByWkByCustToExcel", _
acFormatXLS, "Byron Polk", , , _
"Summary of Womenswear Invoices Due", _
"Attahced is the latest list of Womenswear Invoices
Due.", 0
End If
This issue seems to be something related to the SendObject not being
released or completed, but I just cannot find any solution.
Any assistance is apprecitate.
Mr B