Page 1 of 2 12 LastLast
Results 1 to 15 of 16
  1. #1
    Gail is offline Advanced Beginner
    Windows 10 Access 2016
    Join Date
    Jun 2017
    Posts
    34

    Access 2016 sendobject crash

    Hi, I have recently converted a program from Access 2013 to Access 2016.


    Now the Sendobject command works sometimes but other times it will close the program.
    The computer with the problem uses Windows 7 and Office 2016.
    Does anyone know it there's a fix for this?
    thank you

  2. #2
    ranman256's Avatar
    ranman256 is online now VIP
    Windows Vista Access 2010 32bit
    Join Date
    Apr 2014
    Location
    Kentucky
    Posts
    9,524
    I find that conversions can cause problems. I had one keep crashing on the PC.
    We moved it to another PC and it never had a problem.

    you can also try creating an NEW 2016 empty db.
    then IMPORT all objects from the old one.

  3. #3
    Gail is offline Advanced Beginner
    Windows 10 Access 2016
    Join Date
    Jun 2017
    Posts
    34
    Quote Originally Posted by ranman256 View Post
    I find that conversions can cause problems. I had one keep crashing on the PC.
    We moved it to another PC and it never had a problem.

    you can also try creating an NEW 2016 empty db.
    then IMPORT all objects from the old one.

    Thank you for your reply and suggestions.

    The program is on a server and there are about a dozen people running the program from the server.
    It happens on all the computers.

    I have already opened an empty db and imported all the objects.
    It still happens.

  4. #4
    aytee111 is offline Competent At Times
    Windows 10 Access 2013 64bit
    Join Date
    Nov 2011
    Location
    Nomad
    Posts
    3,936
    Are you running Outlook 2016?

  5. #5
    Gail is offline Advanced Beginner
    Windows 10 Access 2016
    Join Date
    Jun 2017
    Posts
    34
    Hi. Yes. We uninstalled office 2013 and installed office 2016

  6. #6
    aytee111 is offline Competent At Times
    Windows 10 Access 2013 64bit
    Join Date
    Nov 2011
    Location
    Nomad
    Posts
    3,936
    There is a lot about this out there, seems it is a known issue. Here are some alternatives: https://access-programmers.com/sendi...om-access-2010

  7. #7
    Gail is offline Advanced Beginner
    Windows 10 Access 2016
    Join Date
    Jun 2017
    Posts
    34
    Thank you for replying and for the link.

    I saw that this is a known issue but it was an issue with an older version of Access (2010 or 2013) using SendObject to Outlook 2016, not with Access 2016 sending to Outlook 2016.

    I also use the other methods of sending an email in the link you provided.
    But for those methods you have to actually save the PDF on the users computer and then attach it to the email.

    SendObject doesn't need to save on their computer and it eliminates so many problems.
    It worked great when I used Office 2013: Access 2013 using SendObject to Outlook 2013.
    Why doesn't it work with Access 2016 using SendObject to Outlook 2016?
    Last edited by Gail; 06-07-2017 at 09:20 PM.

  8. #8
    Micron is online now Virtually Inert Person
    Windows 7 32bit Access 2007
    Join Date
    Jun 2014
    Location
    Ontario, Canada
    Posts
    12,790
    There seems to be a lot written about this issue. Some say it's because the Outlook 2016 version came from Office 365. Others because they switched Outlook from Pop3 to IMAP, or the Access is Runtime version, or it's Access 2013 with Outlook 2016 etc. etc.
    Maybe this won't help, but I'll throw it in anyway since it apparently was solved. - https://www.accessforums.net/showthread.php?t=59392
    The more we hear silence, the more we begin to think about our value in this universe.
    Paraphrase of Professor Brian Cox.

  9. #9
    Gail is offline Advanced Beginner
    Windows 10 Access 2016
    Join Date
    Jun 2017
    Posts
    34
    I'm sorry, but again you showed me a link where the problem is with an older version of Access (2010 or 2013) with Outlook 2016, not Access 2016 with Outlook 2016.
    The program I've written is in several companies with a dozen users each. The work around means saving a PDF to a folder. So then I would need to make sure each User has the same folder to save the PDF to. I know it can be done but it's an extra step from using SendObject. And I use SendObject many times within the program.
    I will do the work, but I still don't feel this issue is solved, since Access 2016 SendObject doesn't work with Outlook 2016.

  10. #10
    aytee111 is offline Competent At Times
    Windows 10 Access 2013 64bit
    Join Date
    Nov 2011
    Location
    Nomad
    Posts
    3,936
    You may be the first to bring this issue up, but the point we are trying to make is that there are known issues in this area, regardless of the version. All users do have the same folders associated with their usernames, such as C:\Users\username... Seeing that you use SendObject so many times, create a function where you pass parameters.

    No, not helping you to solve it, just trying to help with workarounds!

  11. #11
    Gail is offline Advanced Beginner
    Windows 10 Access 2016
    Join Date
    Jun 2017
    Posts
    34
    Ok, thank you, I understand
    A previous reply had said that apparently it had been solved. But I appreciate the ideas for a workaround.
    As mentioned, I will do the work which I meant I would create a function and change all the SendObject commands to use that function.
    Thank you to all who replied, I greatly appreciate it.

  12. #12
    Gail is offline Advanced Beginner
    Windows 10 Access 2016
    Join Date
    Jun 2017
    Posts
    34
    Hi again,
    The problem is still happening.
    I have the Outlook Object Library checked off.
    I replaced all SendObject commands with calls to this routine:

    Public Sub SendFileByEmailDirect(prmEmail As String, prmSubject As String, prmMessage As String, prmFilePathAndName As String)
    10 On Error GoTo Err_SendFileByEmailDirect

    Dim olApp As New Outlook.Application
    Dim olMailItem As Outlook.MailItem

    20 Set olMailItem = olApp.CreateItem(0)

    40 With olMailItem
    50 .Subject = prmSubject
    60 .To = prmEmail
    70 .Body = prmMessage
    80 .Attachments.Add (prmFilePathAndName)
    90 .Send
    100 End With

    Exit_SendFileByEmailDirect:
    120 Set olMailItem = Nothing
    130 Set olApp = Nothing
    140 Exit Sub

    Err_SendFileByEmailDirect:
    150 Call modProcessError("SendFileByEmailDirect", Erl, Err.Number, Err.Description)
    170 Resume Exit_SendFileByEmailDirect

    End Sub


    Sometimes it will work but other times the Access program will close when the user tries to send an email.

  13. #13
    Micron is online now Virtually Inert Person
    Windows 7 32bit Access 2007
    Join Date
    Jun 2014
    Location
    Ontario, Canada
    Posts
    12,790
    The only idea I seem to have remaining is to ensure the shared db is split; i.e. everyone is not using the same front end.

  14. #14
    Gail is offline Advanced Beginner
    Windows 10 Access 2016
    Join Date
    Jun 2017
    Posts
    34
    This was a Microsoft bug and has been fixed in the latest update.

  15. #15
    neo is offline Novice
    Windows 10 Access 2016
    Join Date
    Jan 2020
    Posts
    1
    Hello everybody,
    I have the same problem, window 10 with access 2016 (365).
    I have scheduled windows tasks, every day at the same time to open an access file. When open the access loads a form. In the form event (on load) i run a macro with a query and a macro with send object in order to send pdf with email.
    ~9 times crashes and one works, maybe less...
    i have tried everything and then i found your post.
    Can you pls tell me which is the apdate what solves the problem?
    i realy aprociate any workarround posible solution...

Page 1 of 2 12 LastLast
Please reply to this thread with any new information or opinions.

Similar Threads

  1. Access crash
    By JennyL in forum Access
    Replies: 6
    Last Post: 01-19-2017, 03:42 AM
  2. Replies: 3
    Last Post: 04-21-2016, 06:20 AM
  3. Replies: 15
    Last Post: 06-29-2015, 11:12 AM
  4. Access crash
    By Tjaaaa in forum Access
    Replies: 10
    Last Post: 03-07-2014, 05:41 PM
  5. Diagnose Access Crash
    By Gray in forum Forms
    Replies: 0
    Last Post: 05-28-2011, 01:50 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums