Skip to main content

Bulk Emailing

Bulk Email Processing

Integration Utilities in DPL Studio can be used to retrieve mailing list data from database tables and send emails using:

a. External files
b. Transformation queries
c. Integration utilities

This utility can also be used to:

a. Collect contact information from CRM systems such as Microsoft CRM
b. Retrieve contacts from contact management applications such as ACT!
c. Combine and de-duplicate email lists
d. Send bulk emails automatically

This example demonstrates how to retrieve email data using function parameters and send bulk emails using the Bulk Email utility.

In this example:

a. Parameters are retrieved from the Members section.
b. The corresponding properties are displayed in the Properties section of the Function Parameters dialog box.
c. The parameter name InTable is passed to the GetQuery() function.
d. The parameter InTable contains: ParamType: Query, ParamValue: Email Addresses

The transform query EmailAddresses contains data similar to:

array("sales@riseglobal.net", "support@riseglobal.net") as To,
array("sales", "support") as FirstName

The FirstName parameter is referenced in the HTML file using placeholders such as: Dear {FirstName}

Sample Code
using Data Process Logic.DataEngine;
using Data Process Logic.Connectors.ConnectorInterfaces;
using Data Process Logic.IntegrationUtils;

public class BulkEmailProcessing : IIntegrationFunction {

public void Execute(DataEngine theEngine) {

IntegrationUtils.Initialize(theEngine);

IDataCachedTable tbl = theEngine.GetQuery("InTable");

BulkEmail be = new BulkEmail(tbl);

be.From = "info@riseglobal.net";

be.SmtpHost = "mail.riseglobal.net";

be.HtmlFilePath = @"%FPDIR%\EMailMsg.htm";

be.Subject = "Sending bulk email";

// Optionally add an attachment

// be.AddAttachment(@"%FPDIR%\Data Process LogicStudio.png");

// Add embedded HTML resources.
// Embedded resources such as images become part of the HTML document.
// They can be referenced in the HTML file using:
// <img src=cid:DPLLogo>

be.AddEmbeddedResource( @"%FPDIR%\Data Process LogicLogo.png", "DPLLogo" );
be.Send();

System.Console.WriteLine(
"Message has successfully sent"
);
}
}

Features Demonstrated

This example shows how to:

a. Retrieve email data using Integration Functions
b. Send bulk emails using query data
c. Use HTML email templates
d. Insert dynamic parameters into email content
e. Add email attachments
f. Embed images and resources inside HTML emails
g. Send emails through an SMTP server