Re: CDO Message Problem



Addition of the "tester" function alone did not work for me.
However when I modified the script to attach the file with the same
html content I send, everything worked fine.

I added the following code:

Set fso = CreateObject("Scripting.FileSystemObject")
Set testfile= fso.CreateTextFile("main.html", True)
testfile.Write VBody
testfile.Close
objMessage.AddAttachment "C:\MyPath\main.html"

It is at least strange. Fortunately, this work around suits me :)


9ntw9 ra?e:
I used the code to send it to a directory, and checked the files ...

I had set ContentTransferCoding = "quoted-printable" in iBp3 (an
additional body part of my base iBp1), but had never set iBp1, so it
was sending in 7bit.

Hopefully this has fixed my problem!

p.s. to anyone attempting to use the code in the previous msg, I had to
change oConf.Update to oConf.Fields.Update to get it running.

I'll run some tests (with fingers crossed) and let everyone know if
this fixed it.

Thanks!

Anthony Jones wrote:
"9ntw9" <nathaniel.williams@xxxxxxxxx> wrote in message
news:1167944823.401987.233270@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Thanks for your time,

Here is the code being used to send the mail:

Set objMail = Server.CreateObject("CDO.Message")
objMail.MIMEFormatted=true
objMail.From = sFrom
objMail.To = sTo
objMail.Subject= sSubject
objMail.HTMLBody = sTextBody
objMail.Send

I set the MIMEFormatted = True after reading an article that suggested
it would fix the problem, but no luck. (There was no apparent change)


Try this:-

Create an empty folder E.g. c:\temp\pickup

Now add this code after creating objMail :-

Dim oConf: Set oConf = objMail.Configuration
oConf.Fields("http://schemas.microsoft.com/cdo/configuration/sendusing";)= 1
'Use pickup folder
oConf.Fields(http://schemas.microsoft.com/cdo/configuration/smtpserverpickup
directory") = _
"c:\temp\pickup"
oConf.Update

Now when you execute your code you should get an .eml file appear in pickup
folder. You can open this file in outlook express to see if it is mangled
before it's ever passed through a SMTP server. You can also open it in
notepad to see exactly what has been generated.

The header to the HTML body part should look something like this:-

------_=_NextPart_003_01C657E9.493172D2
Content-Type: text/html;
charset="us-ascii"
Content-Transfer-Encoding: quoted-printable

.



Relevant Pages

  • Re: CDO Message Problem
    ... additional body part of my base iBp1), but had never set iBp1, so it ... Dim oConf: Set oConf = objMail.Configuration ... 'Use pickup folder ...
    (microsoft.public.inetserver.asp.components)
  • Re: Turner Audio website being re-furbished.
    ... > Before you fuck up again, Patrick, a) correct the spelling of Mozart's ... > single folder. ... Then i had a lot of other html pages linked off a folder called webpgs.html, ... > ISP where your site will be available to the public. ...
    (rec.audio.tubes)
  • Re: How do I Save from MHTML .mht to HTML format only
    ... The issue was the difference between html and htm on the index folder so I ... I also notice that your host says you have to use the .html extension for ... Double check that you did indeed upload to the ...
    (microsoft.public.publisher.webdesign)
  • Re: What are these??
    ... SetupHlp.cmd that copies altsvc to the Windows\System32 ... ntdll.dll file which should be in the Windows\System32 folder, ... Only open HTML documents with Notepad. ... > There has been no apparent effect of shifting both msthost and altsvc out ...
    (microsoft.public.windowsxp.general)
  • Re: What are these??
    ... SetupHlp.cmd that copies altsvc to the Windows\System32 ... ntdll.dll file which should be in the Windows\System32 folder, ... Only open HTML documents with Notepad. ... > There has been no apparent effect of shifting both msthost and altsvc out ...
    (microsoft.public.windowsxp.perform_maintain)

Loading