Solved

DoCmd.SendObject acSendNoObject

Posted on 2004-08-26
5
680 Views
Last Modified: 2012-06-27
Hi,

I am running the following code on two seperate systems. One works the other errors constantly;

If Not IsNull(Me.HD_Email) Then
    strMsg = MsgBox("Do You Want To Send This Customer An Email?", vbYesNo, ConTitle)
        If strMsg = vbNo Then Exit Sub
   
        DoCmd.SendObject acSendNoObject, , , Me.HD_Email, , , "At Home In London"

        Exit Sub
Else
    MsgBox "No Email Address Found For This Customer", vbOKOnly, ConTitle
    Exit Sub
End If

-----------
Using Access 2002. the error message as follows

(From)Microsoft Exchange
The Object Could Not Be Found

Followed by error from Access.
2993
Can't send this message

would appreciate any help

Scott
0
Comment
Question by:scottsanpedro
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
5 Comments
 
LVL 26

Expert Comment

by:dannywareham
ID: 11901951
0
 
LVL 1

Author Comment

by:scottsanpedro
ID: 11901973
yep...i've been everywhere :)
0
 
LVL 26

Expert Comment

by:dannywareham
ID: 11902071
Okey doke

What are you trying to do - just send an email without an attachment through Outlook?
0
 
LVL 26

Accepted Solution

by:
dannywareham earned 150 total points
ID: 11902094
If so, it may be better to do it through a different code:

'* Set a reference to 'Microsoft Outlook 9.0 Object Library  *
'* (or any other version)                                    *
'* Menu 'Tools', 'References', check the appropriate library *
'*************************************************************
Private Sub Knop1_Click()
Dim ol As New Outlook.Application
Dim olMail As Outlook.MailItem
Dim strTO As String
Dim strCC As String

   strTO = "Who@where.com"
   'strCC = "who@domain.com" & ";" & "who2@domain.com"


    Set olMail = ol.CreateItem(olMailItem)

    With olMail
        .To = strTO
        '.CC = strCC
        '.BCC = "address2@aa.com"
        '.Attachments.Add "c:\somefile.txt"
        '.Attachments.Add "c:\somefile2.txt"
        .Subject = "Testing"
        .Body = "This is the body..."
        .Display
        '.Send
    End With

    Set olMail = Nothing
    Set ol = Nothing

End Sub

I've ' out some of the code, so that you can add or remove it as nessessary
0
 
LVL 1

Author Comment

by:scottsanpedro
ID: 11902581
Thanks Danny...looks like it could work

I will check later as away for a bit...thank you and will get back

0

Featured Post

Free Tool: Postgres Monitoring System

A PHP and Perl based system to collect and display usage statistics from PostgreSQL databases.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

A simple tool to export all objects of two Access files as text and compare it with Meld, a free diff tool.
Describes a method of obtaining an object variable to an already running instance of Microsoft Access so that it can be controlled via automation.
Familiarize people with the process of retrieving data from SQL Server using an Access pass-thru query. Microsoft Access is a very powerful client/server development tool. One of the ways that you can retrieve data from a SQL Server is by using a pa…
With Microsoft Access, learn how to specify relationships between tables and set various options on the relationship. Add the tables: Create the relationship: Decide if you’re going to set referential integrity: Decide if you want cascade upda…

696 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question