Views:

Scenario Overview

The business requirement here is that we have a 3rd party integration creating Account records within Dynamics CRM. This integration cannot set the ownerid field of the record  but it can set a text field with the name of the owner. So we need to use this information to lookup the User ID value & set it to the owner of the Account record. 

N52 Formula Manager Solution

The Formula Manager solution works like this,

  • A formula is set to execute for the create event of the Account entity
  • It checks that the OwnerText field has data before it executes the main formula
  • When the formula executes it uses the FindValue() function to lookup the guid of the systemuser based on the value of the OwnerText field
  • It uses this guid to set the ownerid field of the Account record

N52 Formula Manager Steps

The following set of steps will set this formula up for you.

  • Create a new formula of type 'Save - Perform Action'
  • Set the Source Entity to 'Account'
  • Set the Source Property to 'Owner Text'
  • Set the Event pick-list field to 'Create'
  • Copy & paste the formula below into the formula description field
  • Click Save
  • Ready to test.

Formula

UpdateRecord('account', 
            [account.accountid], 
            SetAttributeLookup('ownerid', 
                               'systemuser',
                                 FindValue('systemuser', 
                                           'fullname',
                                           [account.new_ownertext],
                                           'systemuserid'))
                   )

Wizard - ClientSideDate

Please see below the wizard you can use to create the ClientSideDate() function call used in this formula. 

Note to find the value for Equals Value, you will need to go to the Source tab and find the field. 

 

Did you know?

You can create customized buttons to trigger complex business rules

North52's Decision Suite has functionality that we call Quick Buttons that allows you to place buttons on a form which when clicked will trigger a North52 Formula.  The business rule logic could be as simple as triggering a workflow or a much more complex process which involves many actions - the full power of the North52 business rules engine for Dynamics 365 can be used. 

The button's themselves can be subject to business rules, that show/hide, activate/deactivate or and/or change labels. This is configured using Decision Tables allowing complex decision logic to drive the button options that are presented to users.

Learn more about Quick Buttons