473,396 Members | 2,111 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,396 software developers and data experts.

CDO message help

Hi All,
Need CDO help
<%@ Language=VBScript %>
<%
Dim iMsg
Dim iConf
Dim Flds
Set iMsg = CreateObject("CDO.Message")
Set iConf = CreateObject("CDO.Configuration")
Set Flds = iConf.Fields
Flds("http://xyz.com") = True
Flds.Update

With iMsg
Set .Configuration = iConf
.CreateMHTMLBody "http://xyz.com"
.HTMLBody="<h1>Jishnu</h1>
.To = "ji*****************@clout.com"
.From = "CLOUT Reporting Unit <Re*******@clout.com>"
.Subject = "Daily Snapshot Report"
.Send
End With
%>

The problem with this it does not CreateMHTMLBODY but if I take the
..HTMLBODY off then .CReateMHTMLBODY works.
I need to add some HTML body along with the url.
Does anyone know how to correct the code.
Thanks
Jul 19 '05 #1
1 2836
You're overwriting the body with the code you have. The .CreateHTMLBody
method grabs the HTML string and gives that value to the .HTMLBody property.
It'd be as though you're doing this:

..HTMLBody = "hi"
..HTMLBody = "bye"

Would you expect "hibye" to be the .HTMLBody then? No, it'd just be "bye."
If you want to concatenate more html to the body, do:

..CreateHTMLBody "http..."
..HTMLBody = .HTMLBody & "<h1>.." '<--don't forget closing " as you did
below

Ray at work

"Jishnu" <ji******@yahoo.com> wrote in message
news:80*************************@posting.google.co m...
Hi All,
Need CDO help
<%@ Language=VBScript %>
<%
Dim iMsg
Dim iConf
Dim Flds
Set iMsg = CreateObject("CDO.Message")
Set iConf = CreateObject("CDO.Configuration")
Set Flds = iConf.Fields
Flds("http://xyz.com") = True
Flds.Update

With iMsg
Set .Configuration = iConf
.CreateMHTMLBody "http://xyz.com"
.HTMLBody="<h1>Jishnu</h1>
.To = "ji*****************@clout.com"
.From = "CLOUT Reporting Unit <Re*******@clout.com>"
.Subject = "Daily Snapshot Report"
.Send
End With
%>

The problem with this it does not CreateMHTMLBODY but if I take the
.HTMLBODY off then .CReateMHTMLBODY works.
I need to add some HTML body along with the url.
Does anyone know how to correct the code.
Thanks

Jul 19 '05 #2

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

Similar topics

7
by: Rainmaker | last post by:
Greetings, I have not been able to find the documentation that will allow me to insert php code inside the html code in the $message block in the mail() function. Using the example in the help...
0
by: python-help-bounces | last post by:
Your message for python-help@python.org, the Python programming language assistance line, has been received and is being delivered. This automated response is sent to those of you new to...
5
by: Bob Darlington | last post by:
When compiling my help file, I get the following message: 'HC3108: Warning: topic #65 of C:\Program Files\DPC Manager 10\help\dpchelp.rtf : The title footnote ($) does not appear before any...
1
by: Dan | last post by:
I can't figure out this error message. Could someone please help. I have a text file in Notepad with the following 4 fields (Cont, Code, List, and Numb)all of which are single tab delimited, and a...
3
by: Serious_Practitioner | last post by:
Hello, all - A few days ago, I posted the following message - Hello all, and thank you for your help in the recent past. Got a new error message in the last few days. While working with...
1
by: Serious_Practitioner | last post by:
Good day - As you suggested, I got and used the right version of Jetcomp, and I also tried to run compact and repair a couple of times. I think that the compact and repair process doesn't fully...
10
by: ahager via DotNetMonster.com | last post by:
I am receiving this messaage in a console application I wrote, I am authenticating, and my network admin swears their is nothing wrong with the smtp server. Any ideas? public void Mail_update()...
14
by: Bernie Yaeger | last post by:
OK - I'm very close. I'm running a console app on a server and it fails with cdo .message failure. It's a simple email routine which works fine on my development pc. Do you have any idea what...
7
by: Tony Girgenti | last post by:
Hello. I'm developing and testing a web application using VS.NET 2003, VB, .NET Framework 1.1.4322, ASP.NET 1.1.4322 and IIS5.1 on a WIN XP Pro, SP2 computer. I'm using a web form. I'm...
4
by: Count László de Almásy | last post by:
Is there a standard way with optparse to include a blurb of text after the usage section, description, and the list of options? This is often useful to include examples or closing comments when...
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: 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
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
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...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

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.