473,657 Members | 2,405 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

CreateMHTMLBody with local ASP URL doesn't work

Here's my scenario. I have an ASP page that I call on my server, say:

http://myserver.com/firstPage.asp

In this first ASP page, I want to send a MIME email that has the
contents of another ASP page which is located on the same server. So
the code looks like:

<%
Set objCdoMesg = Server.CreateOb ject("CDO.Messa ge")
objCdoMesg.Crea teMHTMLBody("ht tp://myserver.com/secondPage.asp" )
objCdoMesg.To = "me@mymail. com"
objCdoMesg.From = "me@mymail. com"
objCdoMesg.Subj ect = "Testing MIME messages"
objCdoMesg.Send
%>

This process will hang on the CreateMHTMLBody () method call. If I
move the second page to another server and reference it there, it's
fine. If I rename the second page to "secondPage.htm l" and leave it
on the local server and reference it that way (the second page doesn't
have any ASP code in it at this point, just HTML), it's fine.

It seems like the only time the hang occurs is when the requested file
is an ASP page and is located on the local server.

Anyone seen anything like this? I'm running on Windows 2000 Server
with all the current security updates. Seems like it may be something
in the way the process(es) are running.

Thanks,
Kevin
Jul 21 '05 #1
4 4905
Have a look at this:
http://support.microsoft.com/default...b;en-us;290591
it may be a similar problem.
--
--Mark Schupp
Head of Development
Integrity eLearning
www.ielearning.com

"Braky Wacky" <he***********@ hotmail.com> wrote in message
news:4e******** *************** ***@posting.goo gle.com...
Here's my scenario. I have an ASP page that I call on my server, say:

http://myserver.com/firstPage.asp

In this first ASP page, I want to send a MIME email that has the
contents of another ASP page which is located on the same server. So
the code looks like:

<%
Set objCdoMesg = Server.CreateOb ject("CDO.Messa ge")
objCdoMesg.Crea teMHTMLBody("ht tp://myserver.com/secondPage.asp" )
objCdoMesg.To = "me@mymail. com"
objCdoMesg.From = "me@mymail. com"
objCdoMesg.Subj ect = "Testing MIME messages"
objCdoMesg.Send
%>

This process will hang on the CreateMHTMLBody () method call. If I
move the second page to another server and reference it there, it's
fine. If I rename the second page to "secondPage.htm l" and leave it
on the local server and reference it that way (the second page doesn't
have any ASP code in it at this point, just HTML), it's fine.

It seems like the only time the hang occurs is when the requested file
is an ASP page and is located on the local server.

Anyone seen anything like this? I'm running on Windows 2000 Server
with all the current security updates. Seems like it may be something
in the way the process(es) are running.

Thanks,
Kevin

Jul 21 '05 #2
Did you try using 127.0.0.1, or localhost?

--
http://www.aspfaq.com/
(Reverse address to reply.)


"Braky Wacky" <he***********@ hotmail.com> wrote in message
news:4e******** *************** ***@posting.goo gle.com...
Here's my scenario. I have an ASP page that I call on my server, say:

http://myserver.com/firstPage.asp

In this first ASP page, I want to send a MIME email that has the
contents of another ASP page which is located on the same server. So
the code looks like:

<%
Set objCdoMesg = Server.CreateOb ject("CDO.Messa ge")
objCdoMesg.Crea teMHTMLBody("ht tp://myserver.com/secondPage.asp" )
objCdoMesg.To = "me@mymail. com"
objCdoMesg.From = "me@mymail. com"
objCdoMesg.Subj ect = "Testing MIME messages"
objCdoMesg.Send
%>

This process will hang on the CreateMHTMLBody () method call. If I
move the second page to another server and reference it there, it's
fine. If I rename the second page to "secondPage.htm l" and leave it
on the local server and reference it that way (the second page doesn't
have any ASP code in it at this point, just HTML), it's fine.

It seems like the only time the hang occurs is when the requested file
is an ASP page and is located on the local server.

Anyone seen anything like this? I'm running on Windows 2000 Server
with all the current security updates. Seems like it may be something
in the way the process(es) are running.

Thanks,
Kevin

Jul 21 '05 #3
I was thinking it was probably something along those lines, i.e. a
threading issue with the process. I've since backed out of the plan
to use that functionality in favor of a reasonable workaround. Thanks
for the link. I knew I had seen something similar with XMLHTTP, but
had forgotten about it.

I may revisit, building the functionality inside of .NET with COM
interop, to see if the .NET runtime plays any nicer with it. But
that's an exercise for another day.

Kevin
"Mark Schupp" <no******@email .net> wrote in message news:<ew******* *******@TK2MSFT NGP10.phx.gbl>. ..
Have a look at this:
http://support.microsoft.com/default...b;en-us;290591
it may be a similar problem.
--
--Mark Schupp
Head of Development
Integrity eLearning
www.ielearning.com

"Braky Wacky" <he***********@ hotmail.com> wrote in message
news:4e******** *************** ***@posting.goo gle.com...
Here's my scenario. I have an ASP page that I call on my server, say:

http://myserver.com/firstPage.asp

In this first ASP page, I want to send a MIME email that has the
contents of another ASP page which is located on the same server. So
the code looks like:

<%
Set objCdoMesg = Server.CreateOb ject("CDO.Messa ge")
objCdoMesg.Crea teMHTMLBody("ht tp://myserver.com/secondPage.asp" )
objCdoMesg.To = "me@mymail. com"
objCdoMesg.From = "me@mymail. com"
objCdoMesg.Subj ect = "Testing MIME messages"
objCdoMesg.Send
%>

This process will hang on the CreateMHTMLBody () method call. If I
move the second page to another server and reference it there, it's
fine. If I rename the second page to "secondPage.htm l" and leave it
on the local server and reference it that way (the second page doesn't
have any ASP code in it at this point, just HTML), it's fine.

It seems like the only time the hang occurs is when the requested file
is an ASP page and is located on the local server.

Anyone seen anything like this? I'm running on Windows 2000 Server
with all the current security updates. Seems like it may be something
in the way the process(es) are running.

Thanks,
Kevin

Jul 21 '05 #4
Yeah, I tried that. I had high hopes for that solution. :) Alas, it
was not meant to be; I saw the same behavior there too. Thanks for
the suggestion though.

Kevin
"Aaron [SQL Server MVP]" <te*****@dnartr eb.noraa> wrote in message news:<#G******* *******@TK2MSFT NGP09.phx.gbl>. ..
Did you try using 127.0.0.1, or localhost?

--
http://www.aspfaq.com/
(Reverse address to reply.)


"Braky Wacky" <he***********@ hotmail.com> wrote in message
news:4e******** *************** ***@posting.goo gle.com...
Here's my scenario. I have an ASP page that I call on my server, say:

http://myserver.com/firstPage.asp

In this first ASP page, I want to send a MIME email that has the
contents of another ASP page which is located on the same server. So
the code looks like:

<%
Set objCdoMesg = Server.CreateOb ject("CDO.Messa ge")
objCdoMesg.Crea teMHTMLBody("ht tp://myserver.com/secondPage.asp" )
objCdoMesg.To = "me@mymail. com"
objCdoMesg.From = "me@mymail. com"
objCdoMesg.Subj ect = "Testing MIME messages"
objCdoMesg.Send
%>

This process will hang on the CreateMHTMLBody () method call. If I
move the second page to another server and reference it there, it's
fine. If I rename the second page to "secondPage.htm l" and leave it
on the local server and reference it that way (the second page doesn't
have any ASP code in it at this point, just HTML), it's fine.

It seems like the only time the hang occurs is when the requested file
is an ASP page and is located on the local server.

Anyone seen anything like this? I'm running on Windows 2000 Server
with all the current security updates. Seems like it may be something
in the way the process(es) are running.

Thanks,
Kevin

Jul 22 '05 #5

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

Similar topics

1
6411
by: Tom_Nolan | last post by:
I am having some trouble with the ASP Script that I have written. It will e-mail me Internet pages and HTML Code just fine, but when I try to have it send an Intranet page, (which is in the same directory), I get an error. This code does not work. myMail.CreateMHTMLBody "file:\\mmcchapdc01\pcfiles\intraday\center.htm"
0
1393
by: Rex | last post by:
Hello... I have a C# app, and am trying to save a web page as a .mht file using CreateMHTMLBody. It was working a while back, but now I am getting "interface not registered" errors when calling the method. Any ideas? I have upgraded to VS 2003, and am wondering if that has something to do with it. I haven't gone thru this code in a while - so I can't say for sure that it stopped working when I "upgraded" to VS2003. I've deleted and...
8
2610
by: Tcs | last post by:
I've been stumped on this for quite a while. I don't know if it's so simple that I just can't see it, or it's really possible. (Obviously, I HOPE it IS possible.) I'm trying to get my queries to run from VB. My pass-thru query retrieves data from our AS/400 that I use to build a local table (on my PC). My pass-thru and local do in fact work together when I run them interactively. But I want, no make that NEED, to run them from VB. ...
0
3129
by: null_port | last post by:
Regarding Peter Bromberg's article on saving web pages as mht's using CDO: http://www.eggheadcafe.com/articles/20040527.asp I've been having fits when calling his sample code: msg.CreateMHTMLBody(url,CDO.CdoMHTMLFlags.cdoSuppressNone, "", "" ); It errors with: "Interface not registered"
0
1464
by: SamNET | last post by:
I have a consistent Problem using CreateMHTMLBod Code works fine in development computer. When published to web it fails consitently at the line MyMsg.CreateMHTMLBody(sURL,CdoMHTMLFlags.cdoSuppressNone I provide a full path (http://www.domain.com/.....etc) to the url at the same site. The URL exists at the site. I can navigate to it. I've tried both "html" and "aspx" extensions Commenting out the line works all the way thru and...
2
3385
by: rschaeferhig | last post by:
I'm writing a .Net 1.1 app that needs to send emails with the body being formed by a locally served web page. Easy to do in legacy ASP. I found that apparently CreateMHTMLBody is not supported via normal System.Web.Mail constructs. It doesn't show up as a method on a message created this way. I found a couple of posts that talked about adding references to CDO for Exchange 2000. I did that and now VS2003 is giving me a correct method of my...
2
5560
by: Richard Schaefer | last post by:
I have a .Net web app (VB) that is creating CDO messages. We save a bunch of content from various sources as a web page on our web server. We then build a CDO message and use CreateMHTMLBody to send the web page. This takes care of embedding images, etc so we don't have to worry about spam filters (it's an internal app so I'm not spamming anyone except our own employees). Recently we had a problem where embedded graphics over about 100kb...
0
1442
by: Richard Schaefer | last post by:
I have a .Net web app (VB) that is creating CDO messages. We save a bunch of content from various sources as a web page on our web server. We then build a CDO message and use CreateMHTMLBody to send the web page. This takes care of embedding images, etc so we don't have to worry about spam filters (it's an internal app so I'm not spamming anyone except our own employees). Recently we had a problem where embedded graphics over about 100kb...
1
2836
by: liorhm | last post by:
Hi everyone, I'm using CDOSYS to send an HTML file to my mailing list (about 800 users), with the following syntax: myMail.CreateMHTMLBody "http://www.xxx.zzz/hello.html" It works fine when the HTML file is only text and colors. When graphics (pictures) are involved, it often doesn't send them at all and the user only gets the text. Does somebody know of a known bug in this command, or maybe a certain restriction I need to follow?...
0
8324
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 effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
8842
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
8740
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 tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
8516
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 Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
8617
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
6176
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5642
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4173
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
2
1733
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.