CDO.Message Issue in Classic ASP running at Windows 2008

Discussion in 'ASP General' started by andre.manhaes@gmail.com, Aug 6, 2012.

  1. Guest

    Hi Everybody,

    I'm struggling over a migration from IIS 6.0/Windows Server 2003 to IIS 7.0/Windows Server 2008 because a classic ASP application isn't working as expected. The problem is when I try to send an email on Windows 2003 using CDOit does it, but running the code on Windows 2008 I got an exception.The following is a piece of code causing the issue:

    Set cdo = Server.CreateObject("CDO.Configuration")
    ...
    ...
    cdoMessage.From = "<email>"
    cdoMessage.To = "email_without_at_or_<>"
    cdoMessage.Subject = Subject
    cdoMessage.HTMLBody = HTMLContent
    cdoMessage.AutoGenerateTextBody = false
    cdoMessage.TextBody = Menstxt
    ....
    ....
    objMessage.Send 'line where's a exception is throw on Windows 2008

    On Windows 2003/IIS 6.0, the application work well even though cdo.Message.To isnt following either the format with enclosures <> or @ followed by a domain, for instance the code works well with cdo.Message.To = "jhf" (for smtp server locally makes sense that email 'jhf', even though without @mydomain.com).

    Using the same code on Windows 2008/IIS 7.0 I get a exception saying "At least one recipient is required, but none were found", CODE: 8004020C.


    Does somene get through similar issue? Is there any configuration to make CDO to stop the verification to the TO field ?

    In my case I cannot change the code because is a legacy application and I'mfrom the infrastructue team.

    Thanks all,
    André
     
    , Aug 6, 2012
    #1
    1. Advertisements

  2. Evertjan. Guest

    wrote on 06 aug 2012 in microsoft.public.inetserver.asp.general:

    > Hi Everybody,
    >
    > I'm struggling over a migration from IIS 6.0/Windows Server 2003 to
    > IIS 7.0/Windows Server 2008 because a classic ASP application isn't
    > working as expected. The problem is when I try to send an email on
    > Windows 2003 using CDO it does it, but running the code on Windows
    > 2008 I got an exception.The following is a piece of code causing the
    > issue:
    >
    > Set cdo = Server.CreateObject("CDO.Configuration")
    > ..
    > ..
    > cdoMessage.From = "<email>"
    > cdoMessage.To = "email_without_at_or_<>"
    > cdoMessage.Subject = Subject
    > cdoMessage.HTMLBody = HTMLContent
    > cdoMessage.AutoGenerateTextBody = false
    > cdoMessage.TextBody = Menstxt
    > ...
    > ...
    > objMessage.Send 'line where's a exception is throw on Windows 2008
    >
    > On Windows 2003/IIS 6.0, the application work well even though
    > cdo.Message.To isnt following either the format with enclosures <> or
    > @ followed by a domain, for instance the code works well with
    > cdo.Message.To = "jhf" (for smtp server locally makes sense that email
    > 'jhf', even though without @mydomain.com).
    >
    > Using the same code on Windows 2008/IIS 7.0 I get a exception saying
    > "At least one recipient is required, but none were found", CODE:
    > 8004020C.
    >
    >
    > Does somene get through similar issue? Is there any configuration to
    > make CDO to stop the verification to the TO field ?


    I would think the requirement of a legitimate To-field is quite
    legitimate.

    Why would you send a message to no-one?

    > In my case I cannot change the code because is a legacy application
    > and I'm from the infrastructue team.


    You should ask them to change the code, methinks.


    --
    Evertjan.
    The Netherlands.
    (Please change the x'es to dots in my emailaddress)
     
    Evertjan., Aug 6, 2012
    #2
    1. Advertisements

  3. G

    Em segunda-feira, 6 de agosto de 2012 14h19min02s UTC-3, Evertjan. escreveu:
    > wrote on 06 aug 2012 in microsoft.public.inetserver.asp.general:
    >
    >
    >
    > > Hi Everybody,

    >
    > >

    >
    > > I'm struggling over a migration from IIS 6.0/Windows Server 2003 to

    >
    > > IIS 7.0/Windows Server 2008 because a classic ASP application isn't

    >
    > > working as expected. The problem is when I try to send an email on

    >
    > > Windows 2003 using CDO it does it, but running the code on Windows

    >
    > > 2008 I got an exception.The following is a piece of code causing the

    >
    > > issue:

    >
    > >

    >
    > > Set cdo = Server.CreateObject("CDO.Configuration")

    >
    > > ..

    >
    > > ..

    >
    > > cdoMessage.From = "<email>"

    >
    > > cdoMessage.To = "email_without_at_or_<>"

    >
    > > cdoMessage.Subject = Subject

    >
    > > cdoMessage.HTMLBody = HTMLContent

    >
    > > cdoMessage.AutoGenerateTextBody = false

    >
    > > cdoMessage.TextBody = Menstxt

    >
    > > ...

    >
    > > ...

    >
    > > objMessage.Send 'line where's a exception is throw on Windows 2008

    >
    > >

    >
    > > On Windows 2003/IIS 6.0, the application work well even though

    >
    > > cdo.Message.To isnt following either the format with enclosures <> or

    >
    > > @ followed by a domain, for instance the code works well with

    >
    > > cdo.Message.To = "jhf" (for smtp server locally makes sense that email

    >
    > > 'jhf', even though without @mydomain.com).

    >
    > >

    >
    > > Using the same code on Windows 2008/IIS 7.0 I get a exception saying

    >
    > > "At least one recipient is required, but none were found", CODE:

    >
    > > 8004020C.

    >
    > >

    >
    > >

    >
    > > Does somene get through similar issue? Is there any configuration to

    >
    > > make CDO to stop the verification to the TO field ?

    >
    >
    >
    > I would think the requirement of a legitimate To-field is quite
    >
    > legitimate.
    >
    >
    >
    > Why would you send a message to no-one?
    >
    >
    >
    > > In my case I cannot change the code because is a legacy application

    >
    > > and I'm from the infrastructue team.

    >
    >
    >
    > You should ask them to change the code, methinks.
    >
    >
    >
    >
    >
    > --
    >
    > Evertjan.
    >
    > The Netherlands.
    >
    > (Please change the x'es to dots in my emailaddress)


    I know it's really strange but the application's users are enterprise one so there's not need to append "@mydomain.com" in the email user.

    Until Windows 2003 emails without domain are acceptable emails for CDO.Message. The issue came up with Windows 2008.
     
    André Manhaes Machado, Aug 6, 2012
    #3
  4. Evertjan. Guest

    André Manhaes Machado wrote on 06 aug 2012 in
    microsoft.public.inetserver.asp.general:

    I wrote:
    [..]
    >> You should ask them to change the code, methinks.


    [please do not quote signatures on usenet]

    > I know it's really strange but the application's users are enterprise
    > one so there's not need to append "@mydomain.com" in the email user.


    No need? I say there is, as you stated.
    On the other hand is there any harm in adding the same?

    appendix = "@gmail.com"
    [...]
    Set cdoMessage = CreateObject("CDO.Message")
    cdoMessage.To = "andre.manhaes" & appendix

    > Until Windows 2003 emails without domain are acceptable emails for
    > CDO.Message. The issue came up with Windows 2008.


    Wasn't it the change from cdonts to cdosys, or was that an earlier MS jump?

    --
    Evertjan.
    The Netherlands.
    (Please change the x'es to dots in my emailaddress)
     
    Evertjan., Aug 6, 2012
    #4
    1. Advertisements

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.
Similar Threads
  1. Guest
    Replies:
    2
    Views:
    1,308
    dave wanta
    Jul 11, 2003
  2. Bob [BVP]
    Replies:
    5
    Views:
    1,068
    Bob [BVP]
    Aug 9, 2004
  3. shapper

    Windows 2008 and SQL 2008

    shapper, Dec 8, 2007, in forum: ASP .Net
    Replies:
    1
    Views:
    564
    Mark Fitzpatrick
    Dec 8, 2007
  4. Julien
    Replies:
    1
    Views:
    2,456
    Cowboy \(Gregory A. Beamer\)
    May 18, 2009
  5. D Averch

    CDO Message not working in Windows 2003

    D Averch, Jul 7, 2004, in forum: ASP General
    Replies:
    2
    Views:
    868
    D Averch
    Jul 7, 2004
  6. Replies:
    0
    Views:
    621
  7. Mike Gale
    Replies:
    4
    Views:
    547
    Steven Cheng [MSFT]
    Sep 11, 2008
  8. Neil Gould

    Classic ASP, CDO.Message, and Server2012

    Neil Gould, Jan 7, 2013, in forum: ASP General
    Replies:
    0
    Views:
    1,892
    Neil Gould
    Jan 7, 2013
Loading...