Using MAILTOOL Distribution Lists to Send Emails to Multiple Recipients from your IBM i


Using MAILTOOL Distribution Lists to Send Emails to Multiple Recipients from your IBM i

For years now MAILTOOL has had it's own distribution list system.  This allows you to send emails to multiple recipients using only a single distribution list name from your IBM i.

Previously this was a feature only available to MAILTOOL Plus customers, but we have also extended that functionality to the base MAILTOOL product as well.

Setting up a distribution list is easy using the MAILTOOL Distribution List Maintenance (MLTDSTL) command:

This display is the main interface for the MAILTOOL distribution lists.  There are functions to add a new list, or import a distribution list from an IBM system list.   In this example we will use the F6 option to create and name a new distribution list, which is pretty self explanatory.

Once you have named the list and given it a description, you can start adding email addresses to it using option 8 next to the list.  This will bring up the MAILTOOL Distribution List Entry Maintenance screen:

If you are working with an existing list this screen will list the email addresses set up in the list.  If not, the list will be empty.  For existing entries you have the option to edit or delete them.  Editing an entry will only allow you to update the description and the type of entry.

If you wish to add a new entry to your distribution list, you can use F6 function key and you will be presented with the following screen:

When adding a new distribution list entry you have 3 fields to use.  

First, enter the email address on the Address line.  Next, enter a description for the entry on the Description line.  This can be the entry's name, or a description.  When sending an email, this value will be used as the description of the email address.

Finally we have the Type line.  On this line you will enter the type of address this is.  The valid values are:

  • DFT - The type of recipient will be dependent on which type of recipient (TO, CC or BCC) the distribution list is specified on on the MAILTOOL command.  For example, if you specify *DFT for the distribution list type and specify the distribution list entry on the CC parameter, this address will be a CC address.
  • *TO - The recipient will always be included as a TO recipient
  • *CC - The recipient will always be included as a CC recipient
  • *BCC - The recipient will always be included as a BCC recipient

To use the distribution list you can use the distribution list ID (preceded by a *) on the TO, CC or BCC paratmers of MAILTOOL (or SPL2EMAIL).  For example:


So, as you can see, setting up distribution lists can be very easy and save a lot of work.  

For example, with our customers we are seeing more and more of them that would like to send emails such as license keys, license renewal notifications and newsletters to a list of addresses, not just one.  In those cases we simply create a distribution list for that customer, adding all of the addresses the customer would like to receive the emails.  Then instead of a single email address we use this distribution list on the MAILTOOL command.

Other customers use this feature and actually update their distributions lists using a program, accessing the files directly and setting the lists to their values before sending the email.  For more information on this feel free to contact me and I am happy to help.

Last edited 06/19/2020 at 10:54:10


Copyright 1983-2024 BVSTools
GreenBoard(v3) Powered by the eRPG SDK, MAILTOOL Plus!, GreenTools for Google Apps, jQuery, jQuery UI, BlockUI, CKEditor and running on the IBM i (AKA AS/400, iSeries, System i).