Monday 20 January 2020

Phone Call Regarding Object Type in Microsoft Flow - Power Automate

Hi Everyone,

Today I got a requirement to update the Case record when a phone call record is created or update under Case. Yes, it is very simple requirement and we can use OOB Workflow and finish it in 10 minutes. As we all know that workflows are getting deprecated, I started using Flow.

It was fine, I have added all the required steps and below is the condition I have taken for checking the regarding object type but when I was testing it was never satisfying. 

Created two steps as Initialize and Set Variable to understand what exactly the value that is coming to the field.

To my surprise, the result is null and my doors are closed to check the condition.
If I leave it like this, the flow will trigger and every phone call create/update and tries to update the Case and fails if the phone call is not associated with the Case record.

After some search came to know that we have to below expression to check the Regarding Type and it worked for me.

triggerOutputs()?['body/_regardingobjectid_type']

Hope this helps.

--
Happy 365'ing
Gopinath

2 comments:

  1. Good one. It helped me to identify the same while I am working on Task entity. Thanks for the article

    ReplyDelete
    Replies
    1. But it's giving plural name not entity schema name.

      Delete