-
[2005] CDO or PIA?
I have an application that requires an email alert to be sent to specific corporate users when the proper conditions exist.
Environment:
Corporate enterprise network
Exchange Server
MS Office 2003
Over 14,000 users in AD
VERY tight security
My application is installed with full-trust privileges.
Would it be best to use CDO (Collaboration Data Objects) to send information directly through Exchange?
Or should I use PIA (Primary Interop Assemblies) to automate MS Outlook?
Keep in mind that the action needs to be transparent to the user (i.e. If using outlook, I don't want to desensitize users to security issues by constantly exposing them to email warnings.).
-
Re: [2005] CDO or PIA?
To do it transparently with a PIA would mean that you would need to support multiple versions of outlook or change the code/compile when Outlook is eventually upgraded. With CDO you will still be subject to certain security restrictions as its not a 100% bypass. Have you considered using the mail class in .NET?
-
Re: [2005] CDO or PIA?
I'm with RD on this... go with option C - use the Mail class built right into .NET.
-tg
-
Re: [2005] CDO or PIA?
By "Mail class" do you mean System.Net.Mail? If so, I thought about that but I had a hard time finding examples for Exchange server. As I'm looking at the documentation, I only see references to SMTP. Can you use System.Net.Mail with Exchange?
-
Re: [2005] CDO or PIA?
If smtp is turned on... which is should be. I ran a test months ago to see how it worked and didn't have any issues...
The trick is making sure the right LogonCredentials is sent.
-tg
-
Re: [2005] CDO or PIA?
Ok, so since we determined that System.Net.Mail is the way to go, I have another question. Using System.Net.Mail is pretty straightforward. However, is it possible to access the current account that is configured in Outlook to obtain the outgoing mail server for non-Exchange clients? Also, is it just me or does the PIA documentation seem to be less thorough than everything else (specifically lacking in examples)?
-
Re: [2005] CDO or PIA?
There is a lot of PIA documentation but it is all written with the most vague explanations.