A few questions come up in the forums @ http://forums.iis.net about people moving Classic ASP applications that use CDONTS. CDONTS was introduced in NT4 and was widely popular. With the success of ASP applications ‘back in the day’, many used CDONTS to send emails from their application. Windows Server 2008 x64 introduces a different challenge. Here is the procedure I used to get CDONTS working.
1) Copy CDONTS.dll from another server to C:\Windows\SysWOW64
2) Run regsvr32 c:\windows\SysWOW64\cdonts.dll
3) Grant the appropriate permissions on C:\inetpub\mailroot\pickup (I granted USERS group Modify permissions). You could get permission denied if the folder security isn’t adjusted.
4) I’m assuming you have installed the SMTP Service located in Server Manager > Features > SMTP Server option
5) Make sure when you when you install the SMTP service, you enable Relay for localhost > Administrative Tools > Internet Information Services (IIS6) > SMTP Virtual Server > Right click, Properties > Access Tab > Relay button > Add 127.0.0.1 in the option. Also enable logging for additional troubleshooting.
‘Ensure logging will work on x64
6) Test using code listed below.
Here is the code to run CDONTS webpage.
Set CDONTSMail = CreateObject(“CDONTS.NewMail”)
CDONTSMail.Subject=”This is a Test email”
strBody = “Thank you for order from www.iislogs.com.” & vbCrLf
I recommend you use CDOSYS instead of CDONTS, however if you are trying to migrate from NT4, 2000/2003 and don’t want to make code changes, hope this helps.
PS:I tested this using Network Service as the application pool user, a custom application pool user, IUSR (default anonymous authentication module user) and the Anonymous Authentication module inherit the application pool user as network service and a custom user. If you are having permissions issues, enable auditing and use process monitor.
Here is a article that can help with auditing. http://weblogs.asp.net/steveschofield/archive/2008/03/07/detecting-permission-issues-using-auditing-and-process-monitor.aspx