473,386 Members | 1,819 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

Email with attach file please

See the ASP code below in order to send an email. How can I attach
a file to this email please?

set objMailer = Server.CreateObject("CDONTS.Newmail")
objMailer.From = "an*******@123.com"
objMailer.To = "an**********@456.com"
objMailer.Subject = "a Subject"
objMailer.Body = “I need to know ASP”

on error resume next
objMailer.Send
if err then
response.Write err.Description
else
'do nothing it went okay
end if

Thanks a lot

Beny

May 2 '07 #1
3 3310

"beny" <be**@discussions.microsoft.comwrote in message
news:58**********************************@microsof t.com...
See the ASP code below in order to send an email. How can I attach
a file to this email please?

set objMailer = Server.CreateObject("CDONTS.Newmail")
objMailer.From = "an*******@123.com"
objMailer.To = "an**********@456.com"
objMailer.Subject = "a Subject"
objMailer.Body = "I need to know ASP"

on error resume next
objMailer.Send
if err then
response.Write err.Description
else
'do nothing it went okay
end if

Thanks a lot

Beny
Get rid of it if you are on Windows 2000 or better and use CDO

http://www.w3schools.com/asp/asp_send_email.asp

--
Mike Brind
May 3 '07 #2
thanks Mike,

i will try it, but please what should i do now?

thanks

beny

"Mike Brind" wrote:
>
"beny" <be**@discussions.microsoft.comwrote in message
news:58**********************************@microsof t.com...
See the ASP code below in order to send an email. How can I attach
a file to this email please?

set objMailer = Server.CreateObject("CDONTS.Newmail")
objMailer.From = "an*******@123.com"
objMailer.To = "an**********@456.com"
objMailer.Subject = "a Subject"
objMailer.Body = "I need to know ASP"

on error resume next
objMailer.Send
if err then
response.Write err.Description
else
'do nothing it went okay
end if

Thanks a lot

Beny

Get rid of it if you are on Windows 2000 or better and use CDO

http://www.w3schools.com/asp/asp_send_email.asp

--
Mike Brind
May 3 '07 #3
Thanks Mike,

You were right. It does perfectly work

Have a good day

Beny

"Mike Brind" wrote:
>
"beny" <be**@discussions.microsoft.comwrote in message
news:58**********************************@microsof t.com...
See the ASP code below in order to send an email. How can I attach
a file to this email please?

set objMailer = Server.CreateObject("CDONTS.Newmail")
objMailer.From = "an*******@123.com"
objMailer.To = "an**********@456.com"
objMailer.Subject = "a Subject"
objMailer.Body = "I need to know ASP"

on error resume next
objMailer.Send
if err then
response.Write err.Description
else
'do nothing it went okay
end if

Thanks a lot

Beny

Get rid of it if you are on Windows 2000 or better and use CDO

http://www.w3schools.com/asp/asp_send_email.asp

--
Mike Brind
May 3 '07 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

15
by: tabonni | last post by:
Hi I try to grab the checked files from HTML page and then send those PDF files as attachments. It can just send email, there are no PDF files attached. Can anybody point out my error? My...
11
by: Chubbly Geezer | last post by:
Hi I'm in the process of converting an access db to vb2005. My old app has code that sends an email with a table attachment formatted to excel. I want to do the same within vb, i.e. create an...
12
by: cj | last post by:
What's the parameter (like ?attachment) or something.
3
by: =?Utf-8?B?SHVnaA==?= | last post by:
Hi There, I use follow code to send email inside VB.NET 2005. It does not work well. Error message of "Failure sending email" would occue. However, email was sent out sometimes. I am confused...
1
by: budyerr | last post by:
All, I am trying to build a email submission form using asp.net. I currently have a web form page that will upload to my webhosting server, attach to email then delete the file after sending. ...
1
by: rahia307 | last post by:
Hi I am using email function in php, and I want to attach a doc file with email. How can I attach doc file with email. If any one have idea about it please help me. Thanks
3
by: jambonjamasb | last post by:
Hi I have two tables: email_tbl Data_table Data table is is used to create a Form Data_form
14
by: sreemathy2000 | last post by:
My requirement is to generate and attach a file and send in an email automatically. i have a existing functionality where i using the code below to write a CSV file in my local system. ...
2
by: Erik Witkop | last post by:
So I have been trying to get this to work all day. I can't get a local file on my web server to attach to an email. Right now I have it printing out in the body of the email. Please help me with...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.