By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
435,595 Members | 3,721 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 435,595 IT Pros & Developers. It's quick & easy.

Sending Webmail through Exchange Server

P: n/a
I've built a small app that sends mail through our ISP's SMTP server but
when I try to send through my local exchange server I get CDO error. Does
webmail use SMTP or does it strictly rely on CDOmail. I don't want to use
the Outlook reference because outlook prompts each time program access it
and I have found a way to disable that. Can I use webmail with exchange?

Thanks
Nov 20 '05 #1
Share this Question
Share on Google+
9 Replies


P: n/a
I have tried both ways of sending email but no success.
1) using System.Web.Mail I get the error
Error: An unhandled exception of
type 'System.Web.HttpException' occurred in system.web.dll
Additional information: Could not access 'CDO.Message'
object.
2) using CDO I get the error
Error: An unhandled exception of
type 'System.Runtime.InteropServices.COMException'
occurred in PrjESITest.exe
Additional information: The transport failed to connect
to the server.
Moreover the Method 1 does not give me any error if i do
not specify the SMTPServer or give a local IP address for
the SMTP Server.
But it works only on some machines.

Could anyone help me with this?

Regards,
Nina

Nov 20 '05 #2

P: n/a
Those are the error I got initially. Thanks

"Nina" <re******@hotmail.com> wrote in message
news:23*****************************@phx.gbl...
I have tried both ways of sending email but no success.
1) using System.Web.Mail I get the error
Error: An unhandled exception of
type 'System.Web.HttpException' occurred in system.web.dll
Additional information: Could not access 'CDO.Message'
object.
2) using CDO I get the error
Error: An unhandled exception of
type 'System.Runtime.InteropServices.COMException'
occurred in PrjESITest.exe
Additional information: The transport failed to connect
to the server.
Moreover the Method 1 does not give me any error if i do
not specify the SMTPServer or give a local IP address for
the SMTP Server.
But it works only on some machines.

Could anyone help me with this?

Regards,
Nina

Nov 20 '05 #3

P: n/a
I haven't had a real chance to test it, I'm fixing to try and implement but
you are using it with an exchange server? Thanks Brian.

"BrianDH" <Br*****@discussions.microsoft.com> wrote in message
news:74**********************************@microsof t.com...
Method 2 is the one I use daily in many of my apps. Have you tried it and what erros do you get?
"B-Dog" wrote:
Those are the error I got initially. Thanks

"Nina" <re******@hotmail.com> wrote in message
news:23*****************************@phx.gbl...
I have tried both ways of sending email but no success.
1) using System.Web.Mail I get the error
Error: An unhandled exception of
type 'System.Web.HttpException' occurred in system.web.dll
Additional information: Could not access 'CDO.Message'
object.
2) using CDO I get the error
Error: An unhandled exception of
type 'System.Runtime.InteropServices.COMException'
occurred in PrjESITest.exe
Additional information: The transport failed to connect
to the server.
Moreover the Method 1 does not give me any error if i do
not specify the SMTPServer or give a local IP address for
the SMTP Server.
But it works only on some machines.

Could anyone help me with this?

Regards,
Nina


Nov 20 '05 #4

P: n/a
I am sorry I did not know where to post the new thread.
Got confused and posted the message here.

I get the following error

Error: An unhandled exception of
type 'System.Runtime.InteropServices.COMException'
occurred in PrjESITest.exe
Additional information: The transport failed to connect
to the server.
-----Original Message-----
Method 2 is the one I use daily in many of my apps. Have you tried it and what erros do you get?
"B-Dog" wrote:
Those are the error I got initially. Thanks

"Nina" <re******@hotmail.com> wrote in message
news:23*****************************@phx.gbl...
> I have tried both ways of sending email but no success. > 1) using System.Web.Mail I get the error
> Error: An unhandled exception of
> type 'System.Web.HttpException' occurred in system.web.dll > Additional information: Could not access 'CDO.Message' > object.
>
>
> 2) using CDO I get the error
> Error: An unhandled exception of
> type 'System.Runtime.InteropServices.COMException'
> occurred in PrjESITest.exe
> Additional information: The transport failed to connect > to the server.
>
>
> Moreover the Method 1 does not give me any error if i do > not specify the SMTPServer or give a local IP address for > the SMTP Server.
> But it works only on some machines.
>
> Could anyone help me with this?
>
> Regards,
> Nina
>


.

Nov 20 '05 #5

P: n/a
I can get it to work with my SMTP server fine but my question was how to
make it work with Exchange since it does not use CDO mail.

"BrianDH" <Br*****@discussions.microsoft.com> wrote in message
news:15**********************************@microsof t.com...
No I am using the SMTP Server on our IIS Server. Exchange plays no part in this that I am aware of.
B

"B-Dog" wrote:
I haven't had a real chance to test it, I'm fixing to try and implement but you are using it with an exchange server? Thanks Brian.

"BrianDH" <Br*****@discussions.microsoft.com> wrote in message
news:74**********************************@microsof t.com...
Method 2 is the one I use daily in many of my apps. Have you tried it
and what erros do you get?

"B-Dog" wrote:

> Those are the error I got initially. Thanks
>
> "Nina" <re******@hotmail.com> wrote in message
> news:23*****************************@phx.gbl...
> > I have tried both ways of sending email but no success.
> > 1) using System.Web.Mail I get the error
> > Error: An unhandled exception of
> > type 'System.Web.HttpException' occurred in system.web.dll
> > Additional information: Could not access 'CDO.Message'
> > object.
> >
> >
> > 2) using CDO I get the error
> > Error: An unhandled exception of
> > type 'System.Runtime.InteropServices.COMException'
> > occurred in PrjESITest.exe
> > Additional information: The transport failed to connect
> > to the server.
> >
> >
> > Moreover the Method 1 does not give me any error if i do
> > not specify the SMTPServer or give a local IP address for
> > the SMTP Server.
> > But it works only on some machines.
> >
> > Could anyone help me with this?
> >
> > Regards,
> > Nina
> >
>
>
>


Nov 20 '05 #6

P: n/a
So are you saying it works for you through your exchange server?

"BrianDH" <Br*****@discussions.microsoft.com> wrote in message
news:96**********************************@microsof t.com...
OK my network guy just told me I was a dumb-A@!... SMTP does go thru Exchange.
Sorry

"BrianDH" wrote:
No I am using the SMTP Server on our IIS Server. Exchange plays no part in this that I am aware of.
B

"B-Dog" wrote:
I haven't had a real chance to test it, I'm fixing to try and implement but you are using it with an exchange server? Thanks Brian.

"BrianDH" <Br*****@discussions.microsoft.com> wrote in message
news:74**********************************@microsof t.com...
> Method 2 is the one I use daily in many of my apps. Have you tried it and what erros do you get?
>
> "B-Dog" wrote:
>
> > Those are the error I got initially. Thanks
> >
> > "Nina" <re******@hotmail.com> wrote in message
> > news:23*****************************@phx.gbl...
> > > I have tried both ways of sending email but no success.
> > > 1) using System.Web.Mail I get the error
> > > Error: An unhandled exception of
> > > type 'System.Web.HttpException' occurred in system.web.dll
> > > Additional information: Could not access 'CDO.Message'
> > > object.
> > >
> > >
> > > 2) using CDO I get the error
> > > Error: An unhandled exception of
> > > type 'System.Runtime.InteropServices.COMException'
> > > occurred in PrjESITest.exe
> > > Additional information: The transport failed to connect
> > > to the server.
> > >
> > >
> > > Moreover the Method 1 does not give me any error if i do
> > > not specify the SMTPServer or give a local IP address for
> > > the SMTP Server.
> > > But it works only on some machines.
> > >
> > > Could anyone help me with this?
> > >
> > > Regards,
> > > Nina
> > >
> >
> >
> >

Nov 20 '05 #7

P: n/a
Hmmn, sounds logical but since I'm getting a CDO error message that is what
bothers me. I know Exchange can SMTP mail but it does not use CDO mail,
only IIS uses CDO mail. I can get it to work through my IIS SMTP server but
not through exchange. I get error message

Could not access 'CDO.Message' object.

I've tried using the DNS name and IP address with no avail. But I do use
SMTP through my exchange server with other devices so I know that isn't the
problem. I have exchange setup that any device can send smtp mail as long
it is on our lan without authentication. I have a feeling that this webmail
is using CDO may be causing the problem on exchange.

"BrianDH" <Br*****@discussions.microsoft.com> wrote in message
news:6C**********************************@microsof t.com...
Ok, I talked to my network gut. He said if exchange is set-up to allow SMTP send Mail then all you need to do is call the DNS or server name. or IP
address to send the mail.
Imports System.Web
Imports System.Web.Mail
Dim aMessage As New MailMessage
aMessage.From = "Em***@address.com"
aMessage.To = "Em***@address.com"
aMessage.Subject = "Report"
aMessage.BodyFormat = MailFormat.Text
aMessage.Body = "String"
SmtpMail.SmtpServer = "smtp.Name_Of_Your_Exchange_Server.com"
SmtpMail.Send(aMessage)

Brian

"B-Dog" wrote:
I can get it to work with my SMTP server fine but my question was how to
make it work with Exchange since it does not use CDO mail.

"BrianDH" <Br*****@discussions.microsoft.com> wrote in message
news:15**********************************@microsof t.com...
No I am using the SMTP Server on our IIS Server. Exchange plays no
part in this that I am aware of.

B

"B-Dog" wrote:

> I haven't had a real chance to test it, I'm fixing to try and
implement but
> you are using it with an exchange server? Thanks Brian.
>
> "BrianDH" <Br*****@discussions.microsoft.com> wrote in message
> news:74**********************************@microsof t.com...
> > Method 2 is the one I use daily in many of my apps. Have you
tried it and
> what erros do you get?
> >
> > "B-Dog" wrote:
> >
> > > Those are the error I got initially. Thanks
> > >
> > > "Nina" <re******@hotmail.com> wrote in message
> > > news:23*****************************@phx.gbl...
> > > > I have tried both ways of sending email but no success.
> > > > 1) using System.Web.Mail I get the error
> > > > Error: An unhandled exception of
> > > > type 'System.Web.HttpException' occurred in system.web.dll
> > > > Additional information: Could not access 'CDO.Message'
> > > > object.
> > > >
> > > >
> > > > 2) using CDO I get the error
> > > > Error: An unhandled exception of
> > > > type 'System.Runtime.InteropServices.COMException'
> > > > occurred in PrjESITest.exe
> > > > Additional information: The transport failed to connect
> > > > to the server.
> > > >
> > > >
> > > > Moreover the Method 1 does not give me any error if i do
> > > > not specify the SMTPServer or give a local IP address for
> > > > the SMTP Server.
> > > > But it works only on some machines.
> > > >
> > > > Could anyone help me with this?
> > > >
> > > > Regards,
> > > > Nina
> > > >
> > >
> > >
> > >
>
>
>


Nov 20 '05 #8

P: n/a
I found this post ...

In the case of WebForms, SMTP email sending is a piece of cake, since it
relies on the server SMTP services being available.

On client WinForms, however, you have to do more work. If you use SMTP
(using System.Web.Mail) then you are forced to rely on SMTP services running
on each client, which will not be available in most cases.

If the computer does NOT have Outlook installed, you will not be able to use
Exchange, though. From my experience with Outlook and Exchange 5.5 - you
will need to log into an Outlook profile in order to create mail objects. If
the Exchange server is not available (which it wont because Outlook isnt
installed and a profile wont be created on the client), you wont be able to
call the Login method and pass it the necessary profile data. You dont HAVE
to specify a profile when you login - if you leave the Profile name blank it
uses the default profile on the client, but this still requires a profile be
present.

Sending email requires SOME kind of protocol. If Outlook isnt available,
perhaps you can connect to an SMTP server elsewhere, but this most certainly
prevents you from using Exchange to do things like save sent messages, for
example.

"BrianDH" <Br*****@discussions.microsoft.com> wrote in message
news:6C**********************************@microsof t.com...
Ok, I talked to my network gut. He said if exchange is set-up to allow SMTP send Mail then all you need to do is call the DNS or server name. or IP
address to send the mail.
Imports System.Web
Imports System.Web.Mail
Dim aMessage As New MailMessage
aMessage.From = "Em***@address.com"
aMessage.To = "Em***@address.com"
aMessage.Subject = "Report"
aMessage.BodyFormat = MailFormat.Text
aMessage.Body = "String"
SmtpMail.SmtpServer = "smtp.Name_Of_Your_Exchange_Server.com"
SmtpMail.Send(aMessage)

Brian

"B-Dog" wrote:
I can get it to work with my SMTP server fine but my question was how to
make it work with Exchange since it does not use CDO mail.

"BrianDH" <Br*****@discussions.microsoft.com> wrote in message
news:15**********************************@microsof t.com...
No I am using the SMTP Server on our IIS Server. Exchange plays no
part in this that I am aware of.

B

"B-Dog" wrote:

> I haven't had a real chance to test it, I'm fixing to try and
implement but
> you are using it with an exchange server? Thanks Brian.
>
> "BrianDH" <Br*****@discussions.microsoft.com> wrote in message
> news:74**********************************@microsof t.com...
> > Method 2 is the one I use daily in many of my apps. Have you
tried it and
> what erros do you get?
> >
> > "B-Dog" wrote:
> >
> > > Those are the error I got initially. Thanks
> > >
> > > "Nina" <re******@hotmail.com> wrote in message
> > > news:23*****************************@phx.gbl...
> > > > I have tried both ways of sending email but no success.
> > > > 1) using System.Web.Mail I get the error
> > > > Error: An unhandled exception of
> > > > type 'System.Web.HttpException' occurred in system.web.dll
> > > > Additional information: Could not access 'CDO.Message'
> > > > object.
> > > >
> > > >
> > > > 2) using CDO I get the error
> > > > Error: An unhandled exception of
> > > > type 'System.Runtime.InteropServices.COMException'
> > > > occurred in PrjESITest.exe
> > > > Additional information: The transport failed to connect
> > > > to the server.
> > > >
> > > >
> > > > Moreover the Method 1 does not give me any error if i do
> > > > not specify the SMTPServer or give a local IP address for
> > > > the SMTP Server.
> > > > But it works only on some machines.
> > > >
> > > > Could anyone help me with this?
> > > >
> > > > Regards,
> > > > Nina
> > > >
> > >
> > >
> > >
>
>
>


Nov 20 '05 #9

P: n/a
Well my whole problem is I want it to go through my exchange server. I
don't want to use CDO mail. I have CDO already on my web server but I want
it to go through exchange. I'll look at other methods. Thanks

"BrianDH" <Br*****@discussions.microsoft.com> wrote in message
news:0A**********************************@microsof t.com...
Did you try the Method 1, installing CDO?

Method 2 runs on our client PCs without Outlook running. Web based and windows based applications.
Damn MS! ;-)
"B-Dog" wrote:
Hmmn, sounds logical but since I'm getting a CDO error message that is what bothers me. I know Exchange can SMTP mail but it does not use CDO mail,
only IIS uses CDO mail. I can get it to work through my IIS SMTP server but not through exchange. I get error message

Could not access 'CDO.Message' object.

I've tried using the DNS name and IP address with no avail. But I do use SMTP through my exchange server with other devices so I know that isn't the problem. I have exchange setup that any device can send smtp mail as long it is on our lan without authentication. I have a feeling that this webmail is using CDO may be causing the problem on exchange.

"BrianDH" <Br*****@discussions.microsoft.com> wrote in message
news:6C**********************************@microsof t.com...
Ok, I talked to my network gut. He said if exchange is set-up to allow
SMTP send Mail then all you need to do is call the DNS or server name. or IP address to send the mail.

Imports System.Web
Imports System.Web.Mail
Dim aMessage As New MailMessage
aMessage.From = "Em***@address.com"
aMessage.To = "Em***@address.com"
aMessage.Subject = "Report"
aMessage.BodyFormat = MailFormat.Text
aMessage.Body = "String"
SmtpMail.SmtpServer = "smtp.Name_Of_Your_Exchange_Server.com"
SmtpMail.Send(aMessage)

Brian

"B-Dog" wrote:

> I can get it to work with my SMTP server fine but my question was

how to > make it work with Exchange since it does not use CDO mail.
>
> "BrianDH" <Br*****@discussions.microsoft.com> wrote in message
> news:15**********************************@microsof t.com...
> > No I am using the SMTP Server on our IIS Server. Exchange plays no

part in
> this that I am aware of.
> >
> > B
> >
> > "B-Dog" wrote:
> >
> > > I haven't had a real chance to test it, I'm fixing to try and

implement
> but
> > > you are using it with an exchange server? Thanks Brian.
> > >
> > > "BrianDH" <Br*****@discussions.microsoft.com> wrote in message
> > > news:74**********************************@microsof t.com...
> > > > Method 2 is the one I use daily in many of my apps. Have you

tried it
> and
> > > what erros do you get?
> > > >
> > > > "B-Dog" wrote:
> > > >
> > > > > Those are the error I got initially. Thanks
> > > > >
> > > > > "Nina" <re******@hotmail.com> wrote in message
> > > > > news:23*****************************@phx.gbl...
> > > > > > I have tried both ways of sending email but no success.
> > > > > > 1) using System.Web.Mail I get the error
> > > > > > Error: An unhandled exception of
> > > > > > type 'System.Web.HttpException' occurred in system.web.dll
> > > > > > Additional information: Could not access 'CDO.Message'
> > > > > > object.
> > > > > >
> > > > > >
> > > > > > 2) using CDO I get the error
> > > > > > Error: An unhandled exception of
> > > > > > type 'System.Runtime.InteropServices.COMException'
> > > > > > occurred in PrjESITest.exe
> > > > > > Additional information: The transport failed to connect
> > > > > > to the server.
> > > > > >
> > > > > >
> > > > > > Moreover the Method 1 does not give me any error if i do
> > > > > > not specify the SMTPServer or give a local IP address for
> > > > > > the SMTP Server.
> > > > > > But it works only on some machines.
> > > > > >
> > > > > > Could anyone help me with this?
> > > > > >
> > > > > > Regards,
> > > > > > Nina
> > > > > >
> > > > >
> > > > >
> > > > >
> > >
> > >
> > >
>
>
>


Nov 20 '05 #10

This discussion thread is closed

Replies have been disabled for this discussion.