Asked by:
Access Crashes When Sending Email

Question
-
We are using Access 2003 with user-level security to manage project activities. Its housed on a remote server which also has MS Office 2010 on it. I am the owner of the database and have built a VBA script to send an email with a report to the purchaser of goods when materials are received in our building.
The VBA script uses "SendObject" using the DoCmd. When I run the script, the email is sent without any problem, but when another user attempts to send the email, the MS Access application crashes. It looks to me like there is some type of permission issue, but I don't know what it would be. I've searched the forums but haven't found a similar problem. Can anyone help me?
Thursday, April 27, 2017 4:11 PM
All replies
-
Have you added error handling to your procedure? What does it return as an error number & description?
Does the user have Outlook installed and configured?
Does your database compile without any errors?
Have you performed a Compact and Repair?
Daniel Pineault, 2010-2016 Microsoft MVP
Professional Support: http://www.cardaconsultants.com
MS Access Tips and Code Samples: http://www.devhut.net- Edited by Daniel Pineault (MVP)MVP Thursday, April 27, 2017 5:00 PM
Thursday, April 27, 2017 4:57 PM -
First of all , let me inform you that the support for MS Office 2003 and the version of MS Office introduced before Office 2003 was already ended.
then also we will try our best to provide you all possible support that we can.
(1) try to check when you send mail in which version of Outlook sent mail displayed?
I assume that both outlook using different mail ids.
(2) check that same version of Outlook is used by another User or different?
(3) other thing I want to suggest you that try to run this code manually on that user machine and check whether it runs successfully or not.
(4) make sure that when he use this line of code in his machine , all the parameters are correct and object is available to send.
(5) is it displaying any confirmation box like below? if yes then click allow.
(6) check that Macro code is set allowed to run in Access Options.
(7) As Daniel Pineault already suggested you try to handle error and let us know about the error. so that we can come to know about the cause for this issue.
(8) try to contact your IT department and take help from Administrator to check that user have proper permissions.
(9) if it is possible for you to upgrade to newer version of Office then try to use the other version of Office that is already installed on your machine to run this code.(for testing purpose)
let us know about your testing results, so that we can try to provide you further suggestions if needed.
Regards
Deepak
MSDN Community Support
Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.Friday, April 28, 2017 2:49 AM -
Sorry it's taken a while to get back to you. I do have error handling on the VBA code, but I'm not receiving an error other than "Microsoft Access has stopped working." When I look at the details, the first line it "APPCRASH". The code I'm using is strVendor = Forms!frmDeliveryRcpt!txbVendor
DoCmd.SendObject acSendReport, "rptDeliveryRcpt", acFormatRTF, "" & strRecipient, , , "Notice of Material Delivery - " & strVendor, "The attached report lists materials you ordered that were delivered to the ISD shop today.", False. All users are accessing the database and the email application from the same computer terminal and the database and email program are on the same remote server. I have compacted & repaired the database. I've de-compile and compiled the database. The other users have had their profiles set-up on the remote server and have no problem using Outlook for regular email. When I run the code, I get the pop up notifying me that Access is trying to send the message through Outlook, buy when the other users run the code, Access crashes before the message notification pop-up appears. I haven't worked with my IT group yet, but you may have something regarding the permissions. That the only thing I can come up with that would make it crash for others, but not myself. Thanks!Wednesday, May 10, 2017 8:56 PM -
Are all users at least able to view or print the report that you're trying to send? This could be a matter of the report being formatted for a specific printer (rather than the default printer) which not all users may have access to in their profile, or a user not having any printers set up at all. First test the report itself and make sure each user can view/print from their own profile.
-Bruce
Wednesday, May 10, 2017 9:44 PM