Automatically Send Email from Access in the next version?

G

Guest

I’ve been reading some of the older threads about sending Outlook email from
Access and it’s obvious this is very confusing to most people, including me.
I use a database program called "Alpha Five" that allows you to send email
from the database without writing a single line of code. It’s very easy and
even incorporates the ability to send HTML messages without any programming.
I find it hard to believe that functionality isn’t in Access 2003 as one must
write some fairly complicated code to get it working.

Having said that, it appears from some of the comments I read that the
ability to automatically send email from Access through Outlook without
writing code may be incorporated into the next version of Access. Can someone
please advise if that’s true?

Thanks,
Robert
 
B

bazoorg

office 2007 beta is available to download and test...

it is very different for office 2003.

i haven't looked much at access 2007...
 
R

Rick Brandt

Robert said:
I've been reading some of the older threads about sending Outlook
email from Access and it's obvious this is very confusing to most
people, including me. I use a database program called "Alpha Five"
that allows you to send email from the database without writing a
single line of code. It's very easy and even incorporates the ability
to send HTML messages without any programming. I find it hard to
believe that functionality isn't in Access 2003 as one must write
some fairly complicated code to get it working.

Having said that, it appears from some of the comments I read that the
ability to automatically send email from Access through Outlook
without writing code may be incorporated into the next version of
Access. Can someone please advise if that's true?

Thanks,
Robert

All versions of Access from Access 95 on up have allowed you to send an
Email without writing any code. What exactly are your Email requirements
that Access is not meeting?
 
G

Guest

Hello Rick:

[All versions of Access from Access 95 on up have allowed you to send an
Email without writing any code. What exactly are your Email requirements
that Access is not meeting?]

That's news to me, but it would make my life much easier. I would truly
appreciate it if you could show me how to do it without writing code. I
would even be happy if I had the code to such because we need this
functionality.

Here at work I've developed an Access application that registers students in
the classes we teach [typcial Many to Many application]. When we bring up a
class, it shows all of the students registered for the class in a One to Many
view. Some of the fields in the child table are the student's ID and email
address.

I want to click a button on the form that will send an HTML formatted email
message, via Outlook, to each student that captures the following information.

StudentID & Student_LastName & Student_FirstName & Student_MI
Class Subject
Class Date
Class Time
Class Location

In sum, we want to send the same message [in HTML] to each student that
essentially says you are registered for the following class and capture the
information described above. We would be happy sending the email one at a
time, or even better, sending all them simultaneously with one click.

Did I adequately explain what we need?

Thanks,
Robert
 
R

Rick Brandt

Robert said:
Hello Rick:

[All versions of Access from Access 95 on up have allowed you to send
an Email without writing any code. What exactly are your Email
requirements that Access is not meeting?]

That's news to me, but it would make my life much easier. I would
truly appreciate it if you could show me how to do it without writing
code. I would even be happy if I had the code to such because we need
this functionality.

Okay, but realize that there is a big difference between "sending an Email
without code" and "sending the specific Email that you require without
code". Any object in an Access file can be sent as an Email attachment by
using the Send... option on the main menu.
Here at work I've developed an Access application that registers
students in the classes we teach [typcial Many to Many application].
When we bring up a class, it shows all of the students registered for
the class in a One to Many view. Some of the fields in the child
table are the student's ID and email address.

I want to click a button on the form that will send an HTML formatted
email message, via Outlook, to each student that captures the
following information.

StudentID & Student_LastName & Student_FirstName & Student_MI
Class Subject
Class Date
Class Time
Class Location

In sum, we want to send the same message [in HTML] to each student
that essentially says you are registered for the following class and
capture the information described above. We would be happy sending
the email one at a time, or even better, sending all them
simultaneously with one click.

Did I adequately explain what we need?

Yes. For that you would need to use code to automate Outlook. Just how
exactly would this other database program you spoke of accomplish the
requirements above without any code or macros required? I find that rather
hard to beleive.

The complexities of using code to automate Outlook or CDO is mostly in
setting up the classes or modules that provide the interface to the external
library. Once that is set up, actually USING that code for individual Email
messages is fairly simple. Have you investigated the code samples available
on the web that allow this? It is mostly a copy and paste operation.
 
G

Guest

Hello Rick:

This is an Access Newsgroup, but since you asked, Alpha Five is a phenomenal
product that actually writes the code for the user after he/she makes their
choices from a feature called "Action Scripting". One just answers a series
of questions such as do you want "Plain Text" or "HTML". Sending email isn't
the only area where Alpha Five excels, it makes Access look complicated
because the program automates almost everything while still giving you the
option to write custom code using Xbasic, their version of Visual Basic.

Anyway, to answer your question, yes I did copy some code and have it
working in plain text. However, the text doesn't line up, and for other
reasons, we want and need HTML formatting. So Rick, that's where the big hang
up is, getting a standard response saying you are registered for the
following class, but doing it in an HTML formatted message so that everything
lines up and we can add a hyperlink.

Robert


Robert said:
Hello Rick:

[All versions of Access from Access 95 on up have allowed you to send
an Email without writing any code. What exactly are your Email
requirements that Access is not meeting?]

That's news to me, but it would make my life much easier. I would
truly appreciate it if you could show me how to do it without writing
code. I would even be happy if I had the code to such because we need
this functionality.

Okay, but realize that there is a big difference between "sending an Email
without code" and "sending the specific Email that you require without
code". Any object in an Access file can be sent as an Email attachment by
using the Send... option on the main menu.
Here at work I've developed an Access application that registers
students in the classes we teach [typcial Many to Many application].
When we bring up a class, it shows all of the students registered for
the class in a One to Many view. Some of the fields in the child
table are the student's ID and email address.

I want to click a button on the form that will send an HTML formatted
email message, via Outlook, to each student that captures the
following information.

StudentID & Student_LastName & Student_FirstName & Student_MI
Class Subject
Class Date
Class Time
Class Location

In sum, we want to send the same message [in HTML] to each student
that essentially says you are registered for the following class and
capture the information described above. We would be happy sending
the email one at a time, or even better, sending all them
simultaneously with one click.

Did I adequately explain what we need?

Yes. For that you would need to use code to automate Outlook. Just how
exactly would this other database program you spoke of accomplish the
requirements above without any code or macros required? I find that rather
hard to beleive.

The complexities of using code to automate Outlook or CDO is mostly in
setting up the classes or modules that provide the interface to the external
library. Once that is set up, actually USING that code for individual Email
messages is fairly simple. Have you investigated the code samples available
on the web that allow this? It is mostly a copy and paste operation.
 
R

Rick Brandt

Robert said:
Hello Rick:

This is an Access Newsgroup, but since you asked, Alpha Five is a
phenomenal product that actually writes the code for the user after
he/she makes their choices from a feature called "Action Scripting".
One just answers a series of questions such as do you want "Plain
Text" or "HTML". Sending email isn't the only area where Alpha Five
excels, it makes Access look complicated because the program
automates almost everything while still giving you the option to
write custom code using Xbasic, their version of Visual Basic.

Anyway, to answer your question, yes I did copy some code and have it
working in plain text. However, the text doesn't line up, and for
other reasons, we want and need HTML formatting. So Rick, that's
where the big hang up is, getting a standard response saying you are
registered for the following class, but doing it in an HTML formatted
message so that everything lines up and we can add a hyperlink.

What kind of code did you copy? If you have code that automates either
Outlook or CDO then both of those can be made to generate an HTML Email.
You would have to supply the proper HTML string for the message though.
 
B

BruceM

Just as a point of information, you can add a hyperlink to a text e-mail
message (at least in Outlook and Outlook Express).

Robert T said:
Hello Rick:

This is an Access Newsgroup, but since you asked, Alpha Five is a
phenomenal
product that actually writes the code for the user after he/she makes
their
choices from a feature called "Action Scripting". One just answers a
series
of questions such as do you want "Plain Text" or "HTML". Sending email
isn't
the only area where Alpha Five excels, it makes Access look complicated
because the program automates almost everything while still giving you the
option to write custom code using Xbasic, their version of Visual Basic.

Anyway, to answer your question, yes I did copy some code and have it
working in plain text. However, the text doesn't line up, and for other
reasons, we want and need HTML formatting. So Rick, that's where the big
hang
up is, getting a standard response saying you are registered for the
following class, but doing it in an HTML formatted message so that
everything
lines up and we can add a hyperlink.

Robert


Robert said:
Hello Rick:

[All versions of Access from Access 95 on up have allowed you to send
an Email without writing any code. What exactly are your Email
requirements that Access is not meeting?]

That's news to me, but it would make my life much easier. I would
truly appreciate it if you could show me how to do it without writing
code. I would even be happy if I had the code to such because we need
this functionality.

Okay, but realize that there is a big difference between "sending an
Email
without code" and "sending the specific Email that you require without
code". Any object in an Access file can be sent as an Email attachment
by
using the Send... option on the main menu.
Here at work I've developed an Access application that registers
students in the classes we teach [typcial Many to Many application].
When we bring up a class, it shows all of the students registered for
the class in a One to Many view. Some of the fields in the child
table are the student's ID and email address.

I want to click a button on the form that will send an HTML formatted
email message, via Outlook, to each student that captures the
following information.

StudentID & Student_LastName & Student_FirstName & Student_MI
Class Subject
Class Date
Class Time
Class Location

In sum, we want to send the same message [in HTML] to each student
that essentially says you are registered for the following class and
capture the information described above. We would be happy sending
the email one at a time, or even better, sending all them
simultaneously with one click.

Did I adequately explain what we need?

Yes. For that you would need to use code to automate Outlook. Just how
exactly would this other database program you spoke of accomplish the
requirements above without any code or macros required? I find that
rather
hard to beleive.

The complexities of using code to automate Outlook or CDO is mostly in
setting up the classes or modules that provide the interface to the
external
library. Once that is set up, actually USING that code for individual
Email
messages is fairly simple. Have you investigated the code samples
available
on the web that allow this? It is mostly a copy and paste operation.
 
G

Guest

Hello Rick:

It would be great if I could make it an HTML formatted message. We really
want to create a standard HTML formatted message that has everything we need
except of course the class and student info. Where would we store that
pre-formatted message?

Any suggestions?

The following code creates an individual email for the student, however,
it's in plain text so it doesn't line up properly and we can't include
hyperlinks.

Private Sub SendEmail_TEST_Click()
Dim SendTo As String, MySubject As String, MyMessage As String
Dim vClassNo As String
Dim vClassDate As String
Dim vStudentID As String
Dim vStudent_Email As String

vClassNo = Me.ClassNo
vClass_Date = Me.Class_Date
vStudentID = Forms.frmClasses.sfrmClassesqrytblLink!StudentID
vStudent_Email = Forms.frmClasses.sfrmClassesqrytblLink!Student_Email


SendTo = vStudent_Email
MySubject = "Class Registration"
MyMessage = "You have successfully registered for training. All of the
details are displayed below" & vbCrLf & "ClassNo is: " & vClassNo & vbCrLf &
" " & "Class Date is:" & vClass_Date & vbCrLf & " " & "StudentID is:" & " " &
vStudentID
DoCmd.SendObject acSendNoObject, , , SendTo, , , MySubject, MyMessage

End Sub

Thanks,
Robert
 
G

Guest

Hi Bruce:

Didn't know that but it was still only one of several reasons why we want
HTML formatting.

Thanks,
Robert

BruceM said:
Just as a point of information, you can add a hyperlink to a text e-mail
message (at least in Outlook and Outlook Express).

Robert T said:
Hello Rick:

This is an Access Newsgroup, but since you asked, Alpha Five is a
phenomenal
product that actually writes the code for the user after he/she makes
their
choices from a feature called "Action Scripting". One just answers a
series
of questions such as do you want "Plain Text" or "HTML". Sending email
isn't
the only area where Alpha Five excels, it makes Access look complicated
because the program automates almost everything while still giving you the
option to write custom code using Xbasic, their version of Visual Basic.

Anyway, to answer your question, yes I did copy some code and have it
working in plain text. However, the text doesn't line up, and for other
reasons, we want and need HTML formatting. So Rick, that's where the big
hang
up is, getting a standard response saying you are registered for the
following class, but doing it in an HTML formatted message so that
everything
lines up and we can add a hyperlink.

Robert


Robert T wrote:
Hello Rick:

[All versions of Access from Access 95 on up have allowed you to send
an Email without writing any code. What exactly are your Email
requirements that Access is not meeting?]

That's news to me, but it would make my life much easier. I would
truly appreciate it if you could show me how to do it without writing
code. I would even be happy if I had the code to such because we need
this functionality.

Okay, but realize that there is a big difference between "sending an
Email
without code" and "sending the specific Email that you require without
code". Any object in an Access file can be sent as an Email attachment
by
using the Send... option on the main menu.

Here at work I've developed an Access application that registers
students in the classes we teach [typcial Many to Many application].
When we bring up a class, it shows all of the students registered for
the class in a One to Many view. Some of the fields in the child
table are the student's ID and email address.

I want to click a button on the form that will send an HTML formatted
email message, via Outlook, to each student that captures the
following information.

StudentID & Student_LastName & Student_FirstName & Student_MI
Class Subject
Class Date
Class Time
Class Location

In sum, we want to send the same message [in HTML] to each student
that essentially says you are registered for the following class and
capture the information described above. We would be happy sending
the email one at a time, or even better, sending all them
simultaneously with one click.

Did I adequately explain what we need?

Yes. For that you would need to use code to automate Outlook. Just how
exactly would this other database program you spoke of accomplish the
requirements above without any code or macros required? I find that
rather
hard to beleive.

The complexities of using code to automate Outlook or CDO is mostly in
setting up the classes or modules that provide the interface to the
external
library. Once that is set up, actually USING that code for individual
Email
messages is fairly simple. Have you investigated the code samples
available
on the web that allow this? It is mostly a copy and paste operation.
 
B

BruceM

OK, just wanted to mention it. You may want to assure the message displays
properly if the recipient has specified plain text messages.

Robert T said:
Hi Bruce:

Didn't know that but it was still only one of several reasons why we want
HTML formatting.

Thanks,
Robert

BruceM said:
Just as a point of information, you can add a hyperlink to a text e-mail
message (at least in Outlook and Outlook Express).

Robert T said:
Hello Rick:

This is an Access Newsgroup, but since you asked, Alpha Five is a
phenomenal
product that actually writes the code for the user after he/she makes
their
choices from a feature called "Action Scripting". One just answers a
series
of questions such as do you want "Plain Text" or "HTML". Sending email
isn't
the only area where Alpha Five excels, it makes Access look complicated
because the program automates almost everything while still giving you
the
option to write custom code using Xbasic, their version of Visual
Basic.

Anyway, to answer your question, yes I did copy some code and have it
working in plain text. However, the text doesn't line up, and for other
reasons, we want and need HTML formatting. So Rick, that's where the
big
hang
up is, getting a standard response saying you are registered for the
following class, but doing it in an HTML formatted message so that
everything
lines up and we can add a hyperlink.

Robert



Robert T wrote:
Hello Rick:

[All versions of Access from Access 95 on up have allowed you to
send
an Email without writing any code. What exactly are your Email
requirements that Access is not meeting?]

That's news to me, but it would make my life much easier. I would
truly appreciate it if you could show me how to do it without
writing
code. I would even be happy if I had the code to such because we
need
this functionality.

Okay, but realize that there is a big difference between "sending an
Email
without code" and "sending the specific Email that you require without
code". Any object in an Access file can be sent as an Email
attachment
by
using the Send... option on the main menu.

Here at work I've developed an Access application that registers
students in the classes we teach [typcial Many to Many application].
When we bring up a class, it shows all of the students registered
for
the class in a One to Many view. Some of the fields in the child
table are the student's ID and email address.

I want to click a button on the form that will send an HTML
formatted
email message, via Outlook, to each student that captures the
following information.

StudentID & Student_LastName & Student_FirstName & Student_MI
Class Subject
Class Date
Class Time
Class Location

In sum, we want to send the same message [in HTML] to each student
that essentially says you are registered for the following class and
capture the information described above. We would be happy sending
the email one at a time, or even better, sending all them
simultaneously with one click.

Did I adequately explain what we need?

Yes. For that you would need to use code to automate Outlook. Just
how
exactly would this other database program you spoke of accomplish the
requirements above without any code or macros required? I find that
rather
hard to beleive.

The complexities of using code to automate Outlook or CDO is mostly in
setting up the classes or modules that provide the interface to the
external
library. Once that is set up, actually USING that code for individual
Email
messages is fairly simple. Have you investigated the code samples
available
on the web that allow this? It is mostly a copy and paste operation.
 
R

Rick Brandt

Robert said:
Hello Rick:

It would be great if I could make it an HTML formatted message. We
really want to create a standard HTML formatted message that has
everything we need except of course the class and student info. Where
would we store that pre-formatted message?

Any suggestions?

What I do in those cases is store the HTML in a memo field of a table from
which I retrieve it when generating the Email. In the "template HTML" I
place markers for data insertion like {AccountNumber} or {CustomerName} and
then I use the Replace() function to replace those markers with the data I
want in the Email.

You cannot use SendObject to do this though. You will need code that
automates Outlook or CDO if you want it to be an HTML message. Those expose
both a Plain Text Body and an HTML Body for the message. If you place your
HTML string into the HTML body then you get an HTML formatted message.
 
G

Guest

Hello BruceM:

That's a moot point because everyone in our agency is using Outlook 2003.

Robert
 
B

Brendan Reynolds

That doesn't necessarily make it a moot point, Robert. I use Outlook 2003
too, but I have it configured to convert all incoming messages to plain
text.

BTW: Here's a link to Eric Rudder's blog posts describing the new
data-collection by e-mail feature in Access 2007. Sounds like it might be of
interest to you.

http://blogs.msdn.com/access/search.aspx?q=email&p=1
 
G

Guest

Hello Brendan:

I'm sure you have a good reason [maybe virus protection?], but I don't
understand why you deprive yourself of one of the coolest features of today's
email programs by converting everything to plain text.

Thanks for pointing me to Rudder's blog, it was very interesting reading and
right on point. I still don't understand why it took MS so long to figure out
that people want and/or need this kind of automated feature built into the
program. By the way, what is Info Path and does it come with Access?

Now if you can help me create an HTML formatted message that advises a
student he/she's registered for a particular course in Access 2003, that
would be very cool and much appreciated.

Robert
 
B

Brendan Reynolds

I do not feel at all deprived by the absence of umpteen different fonts,
colours, and graphics in my e-mail.

InfoPath is a separate application, it is not part of Access. InfoPath 2003
is included only in Microsoft Office Professional Enterprise Edition 2003,
which is available only through Microsoft Volume Licensing and Microsoft
Academic Volume Licensing. If you work in an environment where a substantial
number of your clients have this version of Office, it may be of interest.
For myself, I don't work in such an environment.

I can't personally tell you how to send an HTML-formatted e-mail from
Access, as I have never needed to do that, but here's a link to a Microsoft
web page that might be of interest ...

http://office.microsoft.com/en-us/assistance/HP051876401033.aspx
 
D

dbahooker

that's just flat out not true.

outlook was handicapped in this regard about 6 years ago.

if you want to send emails; setup SQL Server and use Access Data
Projects...

it is QUITE easy to mail from the db server using xp_sendmail

-Aaron
 
D

dbahooker

using CDO or OUltook; I can't remember-- it's just the HtmlBody
property


Brendan said:
I do not feel at all deprived by the absence of umpteen different fonts,
colours, and graphics in my e-mail.

InfoPath is a separate application, it is not part of Access. InfoPath 2003
is included only in Microsoft Office Professional Enterprise Edition 2003,
which is available only through Microsoft Volume Licensing and Microsoft
Academic Volume Licensing. If you work in an environment where a substantial
number of your clients have this version of Office, it may be of interest.
For myself, I don't work in such an environment.

I can't personally tell you how to send an HTML-formatted e-mail from
Access, as I have never needed to do that, but here's a link to a Microsoft
web page that might be of interest ...

http://office.microsoft.com/en-us/assistance/HP051876401033.aspx

--
Brendan Reynolds
Access MVP


Robert T said:
Hello Brendan:

I'm sure you have a good reason [maybe virus protection?], but I don't
understand why you deprive yourself of one of the coolest features of
today's
email programs by converting everything to plain text.

Thanks for pointing me to Rudder's blog, it was very interesting reading
and
right on point. I still don't understand why it took MS so long to figure
out
that people want and/or need this kind of automated feature built into the
program. By the way, what is Info Path and does it come with Access?

Now if you can help me create an HTML formatted message that advises a
student he/she's registered for a particular course in Access 2003, that
would be very cool and much appreciated.

Robert
 
H

Harish

hi,

i have got a database of 1500 email id's in ms access.

i need to mail all of them automatically from microsoft outlook.

how do i do this??

Can anyone help me on this.

Regards
harish

A Womand Told Me
http://www.awomantoldme.com
 
A

AnandaSim

hi,

i have got a database of 1500 email id's in ms access.

i need to mail all of them automatically from microsoft outlook.

how do i do this??

A simplified way if you are using Office 2003 is to run the Mailmerge
Wizard in Word 2003 - this offers to read your Excel file, create an
word document with fields, then invoke Outlook 2003 as the engine to
send out emails.

hth

Ananda
 

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