We help IT Professionals succeed at work.
Get Started

smtp webmail function taking 30 seconds to execute

cseink asked
Last Modified: 2014-05-20
We recently upgraded our exchange to 2010  but now the .net script takes 30 seconds to finish. It sends the email right awway but the page doesn't finish with the thank you until 30 seconds. With 2003 it worked fine.  Looking for any suggestions on what could cause this? The server is at an offsite facility and the 2003 server was in house.

WebMail.SmtpServer = "relay.mail.com";
WebMail.SmtpPort = 25;

 var customerEmail = Request["customerEmail"];
 var customerRequest = Request["customerRequest"];
 // Send email 
WebMail.Send(to:"testemail@testemail.com", subject: "Help request from - " + customerEmail, body: customerRequest ); 
 catch (Exception ex )
//take 30 seconds to get here
thank you for sending

Open in new window

Watch Question
Senior Developer
This problem has been solved!
Unlock 1 Answer and 2 Comments.
See Answer
Why Experts Exchange?

Experts Exchange always has the answer, or at the least points me in the correct direction! It is like having another employee that is extremely experienced.

Jim Murphy
Programmer at Smart IT Solutions

When asked, what has been your best career decision?

Deciding to stick with EE.

Mohamed Asif
Technical Department Head

Being involved with EE helped me to grow personally and professionally.

Carl Webster
CTP, Sr Infrastructure Consultant
Ask ANY Question

Connect with Certified Experts to gain insight and support on specific technology challenges including:

  • Troubleshooting
  • Research
  • Professional Opinions
Did You Know?

We've partnered with two important charities to provide clean water and computer science education to those who need it most. READ MORE