SmtpMail.Send with timeout

I

Ily

Theres not a lot you can do with the mail object sin Dotnet

You might be better looking at some third party component
 
S

stic

but why ?
if she/he need to just do it asynchronously, why she/he need 3rd party
component?

The thread with event rised when the mail couldn't be send is a quite
good solution. But rather for WinForm. In the web the solution I know
is to put mail's in some queue (for example database or flat files with
mails). And use external service (windows service) to handle mail
sending.
If your web application will grow, then a lot of mails will be
generated, and only dedicated service would be able to handle it.
 
R

ra294

I have an ASP.Net application that sends Emails on several pages.
The problem is that when the mail server is down from some reason, the
SmtpMail.Send hangs the application for one minute until I get an exception
that the server is not reponsding.
Is there a way to set a timeout for this operation (for example 5 seconds) ?
Is there another solution for it (sending the mail in new thread ?) ?

Thanks

(e-mail address removed)
 
R

ra294

It's a production application so I don't want to use beta.
BTW, when does .Net 2.0 final will be shipped ?
 
W

William Stacey

Not sure, but VS2005 (w/ .net 2.0) has a go-live license if that helps. I
~think there may just be a RC and then RTM, so it is pretty close. Others
may have better info. Cheers.
 
B

Bruce Barker

nov 7, 2005


-- bruce (sqlwork.com)

ra294 said:
It's a production application so I don't want to use beta.
BTW, when does .Net 2.0 final will be shipped ?
 

Ask a Question

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. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Top