Support for Custom SMTP Configuration

Posted under features on December 20 , 2018 by Swanand Nirgudkar


SheetKraft supports configuration of additional SMTP settings to facilitate automated email sending. The same can be configured in the Runner folder of the SheetKraftWeb instance on the server.

To setup the same create an extra config file in the Runner directory. Let us call it smtp_custom.config; the contents of which will be

<?xml version="1.0"?>
<smtp_custom from="sheetkraft@sheetkraft.com">
  <network host="smtp.gmail.com" port="587" username="sheetkraft@sheetkraft.com" password="password" enablessl="true"/>
</smtp_custom>

Now that the custom config file has been created, add the following emphasized XML in ActivityRunner.exe.config which is also located in the Runner folder in the following manner

<?xml version="1.0" encoding="utf-8"?>
<configuration>
  <configSections>
    .
    .
    .
    <sectionGroup name="mailSettings">
      <section name="smtp_custom" type="System.Net.Configuration.SmtpSection"/>
    </sectionGroup>
  </configSections>
  .
  .
  .
  <system.net>
    <mailSettings>
      <smtp configSource="smtp.config" />
    </mailSettings>
    <connectionManagement>
      <add address="*" maxconnection="256" />
    </connectionManagement>
  </system.net>
  <mailSettings>
    <smtp_custom configSource="smtp_custom.config"/>
  </mailSettings>
  .
  .
  .
</configuration>

Once set up, the custom SMTP configuration can be used to send emails similar to the default smtp usage by specifying it in the SendEmail function.


Tagged:Email

Let's talk

Address

7th floor, Unit No. 701, C Wing, Kailas Business Park, S. Veer Savarkar Marg, Park Site, Vikhroli (W), Mumbai-400079.


Phone

+91 22 62362043


For General Queries

contact@quantumphinance.com


For Technical Support

contact@quantumphinance.com


For Sale and Demos

sales@quantumphinance.com

Thank you for your feedback.