DoCmd.SendObject Fails after converting to .accde Access 365 32-bit

GregTab 1 Reputation point
2021-06-05T20:29:32.277+00:00

I have a simple button on an Access 365 accdb
the button grabs the email address from the form and opens my email program
It works fine on both 32 bit and 64 bit.

when convert the accdb to accde it fails.
on the 32 bit it simply quits the program after about 10 seconds.
in the 64 bit it produces an error 2046 "The command or action SendObject isn't available..."

I have also verified that the location of the files are in a trusted location. I have even added C:\ and all subs as a trusted location.

Code below attached to onClick Button

Dim txt_To As String
On Error GoTo Error_Handler
txt_To = Me.Email
DoCmd.SendObject , , , txt_To, txt_CC, txt_BCC, txt_Subject, txt_Msg
MsgBox "Sucess Your Email has been was Sent to " & txt_To
Error_Handler_Exit:
On Error Resume Next
Exit Sub
Error_Handler:
MsgBox Err.Number & vbCrLf & Err.Description
Resume Error_Handler_Exit

Any suggestions would be helpfull.

Thank you

Access Development
Access Development
Access: A family of Microsoft relational database management systems designed for ease of use.Development: The process of researching, productizing, and refining new or existing technologies.
899 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. DBG 2,376 Reputation points
    2021-06-06T13:22:54.55+00:00

    At the top of your module, add the following line:

    Option Explicit

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.