By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
454,213 Members | 1,307 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 454,213 IT Pros & Developers. It's quick & easy.

Access - Email

P: n/a
Hi,
First I would like to say thanks in advance for any help offered.

i am creating a customer database, when needed i have to have the
ability to click on a client and maybe hit a send email button/link
that will send that client a generic email.

I know this is possible, I just can't figure out how, my hosting does
not support cdonts so i have to use cdo
Again, thanks

Lizz

Nov 13 '05 #1
Share this Question
Share on Google+
7 Replies


P: n/a

fl****@ptd.net wrote:
Hi,
First I would like to say thanks in advance for any help offered.

i am creating a customer database, when needed i have to have the
ability to click on a client and maybe hit a send email button/link
that will send that client a generic email.

I know this is possible, I just can't figure out how, my hosting does
not support cdonts so i have to use cdo
Again, thanks

Lizz


Hmmm ... I hope this isn't for spam!

Option Explicit

Public Sub VerySimpleSendMailWithCDOSample()
' requires reference to cdosys.dll

Dim iCfg As CDO.Configuration
Dim iMsg As CDO.Message

Set iCfg = New CDO.Configuration
Set iMsg = New CDO.Message

With iCfg.Fields
.Item(cdoSendUsingMethod) = cdoSendUsingPort
.Item(cdoSMTPServerPort) = 25
.Item(cdoSMTPServer) = "smtp.mail.yahoo.ca"
.Item(cdoSMTPAuthenticate) = cdoBasic
.Item(cdoSendUserName) = "lylefair"
.Item(cdoSendPassword) = "ThePassWord"
.Item(cdoSendEmailAddress) = "Lyle Fairfield
<ly******@yahoo.ca>"
.Update
End With

With iMsg
.Configuration = iCfg
.Subject = "Test"
.To = "ly***********@aim.com"
.TextBody = "Test"
.Send
End With
End Sub

Nov 13 '05 #2

P: n/a
No it is not for spam, I am a site designer starting to dabble in
database devolpment. This is for a customers site, he wants to be able
to log into members area of his site and from there search client
database and then send client generic email stating their order is in
to pick it up ...... easier i guess then placing a phone call
....................... thank you I will try that code.

Nov 13 '05 #3

P: n/a
See whether there's anything of use to you in the Access EMail FAQ Tony
Toews has at http://www.granite.ab.ca/access/email.htm

--
Doug Steele, Microsoft Access MVP
http://I.Am/DougSteele
(no e-mails, please!)

<fl****@ptd.net> wrote in message
news:11**********************@g14g2000cwa.googlegr oups.com...
Hi,
First I would like to say thanks in advance for any help offered.

i am creating a customer database, when needed i have to have the
ability to click on a client and maybe hit a send email button/link
that will send that client a generic email.

I know this is possible, I just can't figure out how, my hosting does
not support cdonts so i have to use cdo
Again, thanks

Lizz

Nov 13 '05 #4

P: n/a
Are you wanting to send from a website?

Access is a desktop application, you cannot run any code from it on your
browser.

You will have to find out what email software is installed on your host, 99%
of hosting companies have some form of email component you can use.

John

<fl****@ptd.net> wrote in message
news:11**********************@g43g2000cwa.googlegr oups.com...
No it is not for spam, I am a site designer starting to dabble in
database devolpment. This is for a customers site, he wants to be able
to log into members area of his site and from there search client
database and then send client generic email stating their order is in
to pick it up ...... easier i guess then placing a phone call
...................... thank you I will try that code.

Nov 13 '05 #5

P: n/a
THe code I posted works perfectly well from a (MS owered) website, and
simply has to be ported to VB Script or JScript within ASP. In fact,
that's where it originated. Of course, objects may have to be created
rather than referenced.

Nov 13 '05 #6

P: n/a
ok dumb question i'm sure, but where does that code go that lylefair
gave me.

Again thanks for helping
Lizz

Nov 13 '05 #7

P: n/a
hmmm
have you previously used VBA code?

If so, just put the code in a standard module if you want to be able to
call it from wherever.
If you want it private to your form, put it in the form's module.

if you haven't previously used VBA code, you may need to post back and
get bit more help.

Nov 13 '05 #8

This discussion thread is closed

Replies have been disabled for this discussion.