back to top

Setting Lead DNC Fields to Match Do Not Solict Default When Creating New Leads in Infor CRM Web

Within lead records in Infor CRM, there are a number of Do not contact fields, such as DoNotSolicit, DoNotMail, DoNotPhone, etc…  Infor CRM provides an area to set up a default value for the DoNotSolicit value on new Leads, however it does not do anything with the other Do not contact fields.

In InforCRM, the DoNotSolict value supersedes the other Do Not Contact fields, so it shouldn’t matter, however some of our clients find it confusing to have the additional Do Not contact fields not match the Do Not Solicit value when creating a new opportunity.

First of all, how do you set the default for DoNotSolicit?

This is done in the web client under the Custom Settings section on the Administration Navbar.  From there, find the settings with the “Default Settings” category.  Click the Description Link to open the detail view for that setting:

Custom Settings

On the detail for the setting, set the Value to “T” or “F” depending on your needs.

Custom Settings detail

After saving that change, creating new lead (and contact) record will default the DoNotSolicit value to what was specified.

The remaining Do Not Contact fields have no default, so they will be unchecked (false) when the record is created.  How do we get those fields to mirror the defaulted DoNotSolicit value?  We can do this by simply creating a new Event item in the Lead entity.

Post Insert event

We’ll create a new OnAfterInsert event for the Lead entity.  In this database, there is already a primary step, so I created Post Execute Step to contain my code.

And this is the code I added:

namespace Sage.BusinessRules.CodeSnippets
{
    public static partial class LeadBusinessRules
    {
        public static void SetDNCFields( ILead lead)
        {
            // TODO: Complete business rule implementation
            lead.DoNotEmail = lead.DoNotSolicit;
            lead.DoNotFAX = lead.DoNotSolicit;
            lead.DoNotMail = lead.DoNotSolicit;
            lead.DoNotPhone = lead.DoNotSolicit;
            lead.Save();
        }
    }
}

In my code, I’m simply using the DoNotSolicit property to set the other DNC properties.  Since this is an after insert event, we need to Save the change to the Entity values as well.

Something similar could be applied in the Contact entity as well, since contact contains the same DNC fields as the Lead entity.

And that should do it.  Build and Deploy after this change, and your DNC fields should all match up when creating a new record.

Thanks for reading!

 

Contact Customer FX for your CRM project
We let our expertise speak for itself - let us know how our all-star team can help on your CRM project
About the Author
Jason Buss
Jason Buss
Jason is a senior application developer with Customer FX.

LEAVE A REPLY

Please enter your comment!
Please enter your name here

Infor CRM Sync for Exchange: Action Required by August 31, 2026

Using Infor CRM Sync for Exchange with Microsoft 365? Your Exchange administrator must update tenant settings by August 31, 2026 to prevent sync disruption.

[Webinar] What’s Coming Next for Infor CRM SLX and Why v10 Matters

See what’s coming next for Infor CRM SLX, including new marketing workflows, automation improvements, and reasons to consider upgrading to v10.

Disable Caching in Infor CRM SLX Web Client

In the rare case caching is causing issues in the Infor CRM SLX web client, it is possible to disable specific types of caching by making edits using Application Architect, and then deploying.

Exploring AI Options for Infor CRM v10

I've started taking a closer look at the AI capabilities built into Infor CRM v10. Over the next several posts, I'll share what I learn. From the built-in features and supported AI providers to implementation considerations, costs, and practical use cases.

Infor CRM SLX 10.0: Delegate Ownership Changes for “Everyone” Records

Learn how the new EveryoneOwnerAssignment secured action in Infor CRM SLX 10.0 allows designated users to change ownership of Everyone-owned records without requiring Administrator access.

Related Articles

Infor CRM Sync for Exchange: Action Required by August 31, 2026

Using Infor CRM Sync for Exchange with Microsoft 365? Your Exchange administrator must update tenant settings by August 31, 2026 to prevent sync disruption.

[Webinar] What’s Coming Next for Infor CRM SLX and Why v10 Matters

See what’s coming next for Infor CRM SLX, including new marketing workflows, automation improvements, and reasons to consider upgrading to v10.

Disable Caching in Infor CRM SLX Web Client

In the rare case caching is causing issues in the Infor CRM SLX web client, it is possible to disable specific types of caching by making edits using Application Architect, and then deploying.

Exploring AI Options for Infor CRM v10

I've started taking a closer look at the AI capabilities built into Infor CRM v10. Over the next several posts, I'll share what I learn. From the built-in features and supported AI providers to implementation considerations, costs, and practical use cases.

Related Videos