Go Premium for a chance to win a PS4. Enter to Win

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 643
  • Last Modified:

CDO CreateMHTMLBody times out on .asp, but not .htm/.html/etc

I believe I am using CDO.Message, and specifically CreateMHTMLBody, correctly.  In the snippet below, I get the desired behaviour with the following values of "url":

- "http://www.google.ca"
- "http://localhost/testfile.htm"
- "http://127.0.0.1/testfile.htm"
- "http://my-compujter-name/testfile.htm"

But if I try one of the following (which is, of course, just what I need):

- "http://localhost/testfile.asp"
- "http://127.0.0.1/testfile.asp"
- "http://my-computer-name/testfile.asp"

The operation times out.  No entry is made in my machine's Event Log.  We use a proxy server which is bypassed for local addresses, and I tried adding the appropriate entries for the variables cdoURLProxyServer (the IP of the server) and cdoURLProxyBypass (to "<local>") but that didn't change anything.  I also tried setting the Flags parameter to cdoSuppressAll, no dice.  Any experts out there who can help?

snippet:

...
    Set oMailConfig = New CDO.Configuration
    Set Flds = oMailConfig.Fields
    With Flds
      .item(cdoSendUsingMethod) = cdoSendUsingPort
      .item(cdoSMTPServer) = "myMailServer"
      .item(cdoSMTPConnectionTimeout) = 60
      .item(cdoSMTPServerPort) = 25
      .item(cdoSMTPAuthenticate) = cdoAnonymous
      .Update
    End With
   
    Set oMail = New CDO.Message
    With oMail
      Set .Configuration = oMailConfig
            .To = recipients
            .From = sender
            .subject = subject
            .CreateMHTMLBody url
            .Send
    End With
...

0
barryfandango
Asked:
barryfandango
  • 2
1 Solution
 
barryfandangoAuthor Commented:
I think I've discovered the source of the problem.  This code is running in a VB6 COM component called by an ASP webpage.  If i change the variable "url" to point to a test ASP page on another web server on the network, it works properly.  If i point "url" to an .aspx (ASP.NET) file running on the _same_ server, it works.  Thus it appears that the ASP process is locked up using the COM component and will not break to render the page I am trying to attach.

Any ideas, experts?  Looks like an old-fashioned deadlock to me but perhaps there's a way around it.
0
 
barryfandangoAuthor Commented:
I think a refund is in order here, as I never received any response.  I don't want to risk negative feedback, especially in those menacing capitalized letters!
0
 
moduloCommented:
PAQed with points refunded (500)

modulo
Community Support Moderator
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now