views:

840

answers:

2

Hi,

We’re currently in the process of updating the email dispatch part of our application to replace the deprecated set of classes under System.Web.Mail with the System.Net.Mail classes.

The changes have been fairly straightforward but we’ve hit an obstacle today in that we were trying to port the contents of the System.Web.Mail.MailMessage.Fields dictionary (which contains objects mapping to CDO fields) but we cannot see an equivalent on the System.Net.Mail.MailMessage class.

Does anyone know of any documentation which maps the CDO fields to the new classes/properties in the System.Net.Mail classes? (The fields in the namespace can be found here: http://msdn.microsoft.com/en-us/library/ms872853.aspx).

Thanks in advance,

Graham

+1  A: 

which cdo fields are you trying to carry over?

i know some CDO fields we used are now mapped to some properties in the SmtpClient object.

Victor
You're right yeah, the smtpserver, smtpserverport, smtpauthenticate, smtpusessl, sndeusername and sendpassword can all be configured on the SmtpClient class and its associated Credentials property.
Graham
+2  A: 

Have a look at this site http://www.systemnetmail.com/

It should cover all the SMTP related fields that you need to map e.g. ssl, sendusing

Jamie
Thats a really useful site, wish I'd know about it earlier, it would have saved me a lot of time!
Graham