Home   Buy Now   Products   Downloads   Support   Resellers   Jobs   Contact   Site Map   Search
Home   Buy Now   Download   Support  
Email Component, SMTP Component, POP3 Component, IMAP Component, bulk mail

Home
Purchase
Upgrade
 
Products
Downloads
 
Support
 Samples
 KB
 Forum
 
Newsletter
 
Customers
 Current List
 Comments
 
Resellers
Jobs
Contact Us
EasyMail.Net Verify Sample Code

Sample Code

Check out the sample code below to see just how easy it is to use the SSL plug-in to SSL enable EasyMail .Net Edition.  The sample code on this page demonstrates SSL enabling the SMTP component however the SSL plug-in can be used in exactly the same way with the POP3 and IMAP4 components of EasyMail .Net Edition. 

C#   VB.Net   Other Samples    
Sample Notes
This sample shows how to use the SSL plug-in to enabel SSL communications with the EasyMail .Net Edition SMTP component. The highlighted code is the only extra code required to support SSL.  As the example illustrates, all that is necessary to SSL enable the SMTP component is to create an instance of the SSL class and pass it to the Connect() method of the SMTP object.  The SSL plug-in also supports client and server certificates as well as certificate management and enumeration functions.  See the documentation for more information.

//create SMTP object
SMTP objSMTP = new SMTP("mail.domain.com");

//initialize ssl plugin and pass interface to SMTP object
SSL objSSL = new SSL();
objSMTP.Connect(objSSL.GetInterface());

//compose and send message normally
EmailMessage objMessage = new EmailMessage(
                "recipient@domain.com", "sender@domain.com", 
                "Subject", "Body text", BodyPartFormat.Plain);
objSMTP.Send(objMessage);
objSMTP.Disconnect();

Copy and paste this code to get a jump start!

 



 

 Product Home
 Features
 What's New in 3.0
 Features Added in 2.x
 System.Web.Mail Comparison
 SMTP Component
 POP3 Component
 IMAP4 Component
 Parse Component
 SSL Plug-in
 Sample Code
 S/MIME Plug-in
 Documentation
 Pricing / Licensing

©2012Quiksoft Corporation. All rights reserved. Terms of Use, Privacy Statement, Trademarks