Access Automation

B

Bob Barnes

What is the Outlook method to add an Access Unbound textbox (used for
a "message") in automation.

I have....
Dim Outl As Outlook.Application, MyMail As Outlook.MailItem, N$
On Error GoTo AAA1
N = "C:\BobDev\Sales" & Format(BegDaily, "mmddyy") & "_" &
Format(EndDaily, "mmddyy") & ".snp"
DoCmd.OutputTo acOutputReport, "DailySummary", _
"Snapshot Format", N, False
Set Outl = CreateObject("Outlook.Application")
Set MyMail = Outl.CreateItem(olMailItem)
MyMail.To = "(e-mail address removed)"
MyMail.Subject = "Sales Summary" & Format(BegDaily, "mm_dd_yy") & "_"
& Format(EndDaily, "mm_dd_yy")
MyMail.Attachments.Add N

'==Bob..also, I don't want to "Display" the mail and use "SendKeys"..what
command will send the Email w/o displaying it? Thank you.

| 'MyMail.Display
| SendKeys "^{ENTER}"
Set Outl = Nothing: Set MyMail = Nothing
AAA2:
Screen.MousePointer = 1: Exit Sub
AAA1:
Select Case Err
Case Else
MsgBox "Error Number " & Err.Number & " " & Err.Description: Resume
'AAA2 End Select
|
| TIA - B
 
B

Bob Barnes

Sue - It works, but takes a LLOONNGG time vto send from Outlook.

The "warning Message" about someone might be trying to get Outlook
maddresses appears. Is that "Normal" and is there a way to Block that? I
work w/ a network guy who should be able to help w/ that..maybe.

Thank you - Bob
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top