How to Tests Email in ASP.NET Without a Mail Server

If you’ve been testing emails online and is frustrated about it, there is a way in which you can test emails using ASP.NET even without a mail server. This procedure is a bit old but many developers don’t knowabout it. For example you are creating an application to test a module that sends bulk emails. Your first though would be to configure a SMTP server and test the email module. However, there is a trick in which you can test emails without a mail server.

First use this setting in your web config:
<system.net>
<mailSettings>
<smtp deliveryMethod=”SpecifiedPickupDirectory”>
<specifiedPickupDirectory pickupDirectoryLocation=”C:\Mails\”/>
</smtp>
</mailSettings>
</system.net>

The follow additional instructions in this blog:  http://www.devcurry.com/2011/03/test-emails-in-aspnet-without-mail.html

Leave a Reply

Your email address will not be published. Required fields are marked *