Ashfaque
Search Beautiful Girls from your town for night
- Local time
- Tomorrow, 02:17
- Joined
- Sep 6, 2004
- Messages
- 894
Hi,
After executing below code successfully, my email is ready to send.
But in case if I dont want to send the email so I am can cancel or stop sending the email using its X button in outlook. But after than on my form the said dialog box of Run-time error 2501 appearing. And after closing this dialog box, db is running is running smoothly. I want this dialog box not appear.
Code Tags Added by UG
Please use Code Tags when posting VBA Code
https://www.access-programmers.co.u...e-use-code-tags-when-posting-vba-code.240420/
And after email cancelation, the screen is stuck up and unable to do anything except to close it thru task manager. The msg appears the need to terminate the module.
Any help shall be appreciated.
Ashfaque
After executing below code successfully, my email is ready to send.
But in case if I dont want to send the email so I am can cancel or stop sending the email using its X button in outlook. But after than on my form the said dialog box of Run-time error 2501 appearing. And after closing this dialog box, db is running is running smoothly. I want this dialog box not appear.
Code Tags Added by UG
Please use Code Tags when posting VBA Code
https://www.access-programmers.co.u...e-use-code-tags-when-posting-vba-code.240420/
Code:
Dim strMailList, StrCC As String
strMailList = CEmail
StrCC = "ifonat@gmail.com"
DoCmd.SendObject acSendReport, "R_JobOffer", acFormatPDF, strMailList, StrCC, , "JOB OFFER LETTER - " & LetterRefNumber & _
" - " & CName & " - " & Format(Now()), "Dear " & CName & "," & vbCr & vbCr & "With reference to our..... & _
"''''''accept this offer, please sign and re-send back to us as your acceptance." & vbCr & vbCr & "Good Luck and Best Regards," & _
vbCr & vbCr & "Sincerely," & vbCr & vbCr & "Brian Clark" & vbCr & "Human Resources Dept.", True
End If
Any help shall be appreciated.
Ashfaque
Last edited by a moderator: