Referencing Deceased Data before Sending a Text Message

This application was developed using a C# windows form app in Visual Studio 2012.
(Death Index and SMS Notify! along with Excel to mimic a database)

These two services are being utilized to check a list of elderly recipients who have signed up for offers and ensure they have not passed away before sending them discounts via SMS.

The below code was auto-generated after creating a windows form app in Visual Studio 2012.  The form coding section is the overall look of the application.  Customization has been kept to a minimum for clarity purposes.


Next on the code behind page you will want to add the two WSDLs to your project.  Both the SMS Notify! and Death Index WSDLs should be added as a service reference.  Next add your references for Excel, your WSDLs as well as the variables you would like to utilize throughout your application like below.


Next is an example of how you would code your application with an Upload button click event.  This will be used to upload the Excel document that you will be used to validate phone numbers before sending SMS requests.


After the upload button click event we set up the button click event that will set the application into motion.  This process will include opening your file, verifying your data using our Death Index API and sending out your SMS to the appropriate recipients and then save the data back into your Excel document that has been given a new name.

Here is the section where the Excel document is opened, checked for data, and set up for your API calls.


After opening the document and checking that there is data to verify, we then set up the code that will send the data to be verified by CDYNE.  Once verified, the code will tell Excel to populate our document with the appropriate information from the Death Index API you would like to keep.


With this application, we are using the Return Code as well and the error text parameters from the Death Index API as a string.  The code will check specifically for the “3 – No Match” in the Excel document, then send out the SMS to the recipients that are not deceased.


This completes the process needed to complete a basic yet functional windows form application to use with our Death Index and SMS Notify! Services.  You can modify the code provided to best fit your environment and/or purpose.

For more technical information please visit our developer’s Wiki.

Leave a reply