Email from access

  • Thread starter Thread starter Lance McGonigal
  • Start date Start date
L

Lance McGonigal

Thanks in advance for your help.

I know this is a beaten subject but I've been away for a while. What is the
best way to send automated email from access? I'd like to send msgs that
would show up on my companies blackberry.

thanks
 
I use two different methods, depending on whether the machine running the
application has an e-mail client installed or not.

1. SendObject: uses mail client (go to Visual Basic module & look up syntax
for SendObject). If you do not need to send an attachment, there is a
SendNoObject value for one of the arguments
2. Shell to telnet & open connection to an SMTP server on port 25, then
issue commands. This is useful if the machine has no mail client but does not
allow sending of attachments (we rely on the mail client to encode the
attachments correctly). There is a semi-automated application out there
called TST10 that allows one to script this.
 
..SendObject(ObjectType, ObjectName, OutputFormat, To, Cc, Bcc, Subject,
MessageText, EditMessage, TemplateFile)

If ObjectName will be used, an object will be sent as attachment. Is it
possible to send an object in a body of the letter, using MessageText option?
 
You cannot embed an object, but you can enter a multi-line message by doing
something like this:

Dim MsgText as String
MsgText = "Hello. This is line #1."
MsgText = MsgText & Chr(13) 'start a new line
MsgText = MsgText & "This is line #2."

Now do the SendObject and use this MsgText as your message text.
 
Back
Top