Share via

email error 2293 in Access 2003 using SendObject

Anonymous
2011-11-11T22:33:34+00:00

I'm getting a 2293 error "Can't send this message" when attempting to send an email. This has worked for several years, but a customer has installed the program on a new laptop (Win 7), and is getting this error. My program is using the Access 2003 runtime. I simplified the sendobject code down to the absolute basics and gave him the following test program to run. It gives the same error. He is using Windows Live Mail. I've checked several possibilities which were suggested on various sites (default programs, Windows Live Mail update)

Private Sub BtnSendTestEmail_Click()

Dim strRecipient As String

Dim strSubject As String

Dim strBody As String

strRecipient = InputBox("Input E-Mail Address (e.g. ******@yahoo.com)", "Email Address")

strSubject = "Test Email sent at " & Now

strBody = "This test Email was sent at " & Now

On Error GoTo EmailError

DoCmd.SendObject acSendNoObject, , acFormatHTML, strRecipient, , , strSubject, strBody, False

Closeout:

exitsub:

Exit Sub

EmailError:

MsgBox Err.Number & ": " & Err.Description & vbCrLf & _

"SendEMail Error", vbCritical, "Email Error"

Resume Closeout

End Sub

Any other ideas?

thanks,

James

Microsoft 365 and Office | Access | For home | Windows

Locked Question. This question was migrated from the Microsoft Support Community. You can vote on whether it's helpful, but you can't add comments or replies or follow the question.

0 comments No comments

Answer accepted by question author

Tom van Stiphout 40,211 Reputation points MVP Volunteer Moderator
2011-11-12T02:24:47+00:00

Windows Live Mail is a browser based email system, yes? If so, SendObject cannot work with it. It works with locally installed email systems such as Outlook. From the help file:

You can include objects in Microsoft Excel 2000 (*.xls), MS-DOS text (*.txt), rich-text (*.rtf), or HTML (*.html) format in messages for Microsoft Outlook, Microsoft Exchange, or another electronic mail applicationthat uses the Mail Applications Programming Interface (MAPI). (emphasis added TvS)

Was this answer helpful?

0 comments No comments

5 additional answers

Sort by: Most helpful
  1. Tom van Stiphout 40,211 Reputation points MVP Volunteer Moderator
    2011-11-29T03:06:12+00:00

    To bypass the dependency on MAPI, Outlook and some of the security issues around it, you can go directly to the SMTP server.  Here's a paper I wrote on DoCmd SendObject Command in Microsoft Access: Features and Limitations for Sending Emails

    We offer a commercial Microsoft Access add-in, Total Access Emailer, for automating personalized emails from Access.

    Hope this helps.

    But not in the case of Windows Live Mail, the email system the OP was asking about, right?

    Was this answer helpful?

    0 comments No comments
  2. Anonymous
    2011-11-28T14:25:56+00:00

    To bypass the dependency on MAPI, Outlook and some of the security issues around it, you can go directly to the SMTP server.  Here's a paper I wrote on DoCmd SendObject Command in Microsoft Access: Features and Limitations for Sending Emails

    We offer a commercial Microsoft Access add-in, Total Access Emailer, for automating personalized emails from Access.

    Hope this helps.

    Was this answer helpful?

    0 comments No comments
  3. Anonymous
    2011-11-17T14:36:52+00:00

    I just had the customer call me back after installing Outlook. This fixed his problem. Thanks for the input.

    James

    Was this answer helpful?

    0 comments No comments
  4. Anonymous
    2011-11-14T15:46:17+00:00

    I use Outlook, and so didn't even think about this being browser based. Does Win 7 come with a locally installed email program (MAPI)? I just called the customer and suggested he install Outlook.

    Thanks for your feedback. This sounds like it is the problem.

    James

    Was this answer helpful?

    0 comments No comments