M
Marty
ASP.Net, C#, Email message, CDonts not CDO
I am writing an ASP.Net application where I cannot use CDO. I must
use CDonts. I cannot find an example of this on the Internet. I only
see examples on how to do this using CDO. Unfortunately, I don't have
that option. I must use C# and CDonts. Do you have any ideas or
code?
In traditional ASP, the code was:
objMail = Server.CreateObject("CDONTS.NewMail");
objMail.To = "(e-mail address removed)";
objMail.From = "(e-mail address removed)";
objMail.Subject = "Test";
objMail.Importance = 2;
objMail.MailFormat = 0;
objMail.BodyFormat = 0;
objMail.Body = "Test message";
objMail.Send;
How is that ported to .Net in C#? What do you declare the objMail
variable? I tried it as an object variable and .Net didn't like it.
Thanks,
Marty
I am writing an ASP.Net application where I cannot use CDO. I must
use CDonts. I cannot find an example of this on the Internet. I only
see examples on how to do this using CDO. Unfortunately, I don't have
that option. I must use C# and CDonts. Do you have any ideas or
code?
In traditional ASP, the code was:
objMail = Server.CreateObject("CDONTS.NewMail");
objMail.To = "(e-mail address removed)";
objMail.From = "(e-mail address removed)";
objMail.Subject = "Test";
objMail.Importance = 2;
objMail.MailFormat = 0;
objMail.BodyFormat = 0;
objMail.Body = "Test message";
objMail.Send;
How is that ported to .Net in C#? What do you declare the objMail
variable? I tried it as an object variable and .Net didn't like it.
Thanks,
Marty