Solved

Sending e-mail with CDOSYS

Posted on 2012-04-04
4
410 Views
Last Modified: 2012-04-07
I found this code on the page

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


Sending an HTML e-mail that sends a webpage from a website:

<%
Set myMail=CreateObject("CDO.Message")
myMail.Subject="Sending email with CDO"
myMail.From="mymail@mydomain.com"
myMail.To="someone@somedomain.com"
myMail.CreateMHTMLBody "http://www.w3schools.com/asp/"
myMail.Send
set myMail=nothing
%>

I cannot see how this can send as it does not have a button and I do not understand the line myMail.CreateMHTMLBody "http://www.w3schools.com/asp/"

Can anyone explain how this functions please.

Thanks

John
0
Comment
Question by:johnhardy
  • 2
  • 2
4 Comments
 
LVL 29

Expert Comment

by:Paul Jackson
ID: 37806131
The code is server-side code that will execute on the server-side as soon as the page it is on is loaded so it doesn't need a button.

The CreateMHTMLBody line will just take the specified webpage and convert into a format that can be sent as an email body.

http://msdn.microsoft.com/en-us/library/ms527024(v=exchg.10).aspx
0
 

Author Comment

by:johnhardy
ID: 37806281
I was hoping to have a webpage where some entries can be made.

This would seem not to do this?
0
 
LVL 29

Accepted Solution

by:
Paul Jackson earned 500 total points
ID: 37806341
0
 

Author Closing Comment

by:johnhardy
ID: 37819737
Many thanks
excellent
Regards

John
0

Featured Post

What is SQL Server and how does it work?

The purpose of this paper is to provide you background on SQL Server. It’s your self-study guide for learning fundamentals. It includes both the history of SQL and its technical basics. Concepts and definitions will form the solid foundation of your future DBA expertise.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Follow this checklist to learn more about the 15 things you should never include in an email signature from personal quotes, animated gifs and out-of-date marketing content.
Large Outlook files lead to various unwanted errors and corruption issues. Furthermore, large outlook files can also make Outlook take longer to start-up, search, navigate, and shut-down. So, In this article, i will discuss a method to make your Out…
Learn the basics of while and for loops in Python.  while loops are used for testing while, or until, a condition is met: The structure of a while loop is as follows:     while <condition>:         do something         repeate: The break statement m…
In this seventh video of the Xpdf series, we discuss and demonstrate the PDFfonts utility, which lists all the fonts used in a PDF file. It does this via a command line interface, making it suitable for use in programs, scripts, batch files — any pl…

813 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now