Re: Email with MS Access and CDO: showdialog before sending



"john" <hgf@xxxxxxxxxx> wrote in
news:7705$47088817$5354c91b$19971@xxxxxxxxxxxxxxxxxxxxxxx:

I have the following example code. I'm using CDO as I need to specify
the sender.

Set objMessage = CreateObject("CDO.Message")
objMessage.Subject = "Example CDO Message"
objMessage.From = myemailaddress@xxxxxxx
objMessage.To = testaddress@xxxxxxx
objMessage.TextBody = "This is some sample message text."
objMessage.Send

which works, but I have 2 questions:

1. I added the code <<showDialog:=False>> (behind objMessage.Send)
as I want to view the message before I confirm sending. The code is
not accepted.
How can I make this work?

2. I notice that emails that are being send don't end up in my 'sent
box'. Is that possible to achieve?

Thanks in advance,
john

Perhaps, you are trying to use two object models interchangeably.

Typically CDO does not interact directly with Outlook or your default e-
mail program, although it may use values set in Outlook Express.
TTBOMK CDO does not include an object, property or method called
"showDialog"

It would be helpful if you tell us what you are trying to accomplish and/or
show us the whole module, using copy and paste.

--
lyle fairfield

Ceterum censeo Redmond esse delendam
.



Relevant Pages

  • RE: Email Individual Records within a Report / Query
    ... For this you can automate your task either by using Outlook or CDO. ... Set objMessage = CreateObject ... In order to CDO to work, your machine should be installed with IIS SMTP ... Add/Remove Windows Components button. ...
    (microsoft.public.access.reports)
  • Re: Email attachment with CDO
    ... The only CDO ... reference I have is to cdosys.dll. ... Set objMessage = CreateObject ... Dim objMessage As New CDO.Message ...
    (comp.databases.ms-access)
  • CDO and "Line too long" returned email
    ... Occationally the emails bounce with this error: "500 5.5.0 Syntax ... Can I get CDO to handle ... Set objMessage = New CDO.message ...
    (microsoft.public.exchange.development)
  • Create Mailitem with CDO (set from Address )
    ... i want to create a mailitem in den inbox Folder with cdo. ... Set objCDO = Application.CreateObject ... Set objMessage = objCDO.inbox.messages.Add ...
    (microsoft.public.exchange.applications)
  • Creating new Task items by using CDO
    ... Can I create new task item (that uses my custom form) using CDO? ... Set objMessage = CreateObject ... objMessage.TextBody = "This is some sample message text." ...
    (microsoft.public.exchange2000.admin)