PowerAutomate: Perform “Group By” operation on Data

In this post, we'll see how we can perform aggregate function on data such as Sum or Count using PowerAutomate. Unlike LINQ in C# or SQL, it's not very straight forward to do using PowerAutomate for which I thought of sharing the approach we had taken. Recently, we got a requirement to calculate the sum … Continue reading PowerAutomate: Perform “Group By” operation on Data

PowerAutomate: Self-reference is not supported when updating the value of variable

We often come across requirements in which we want to add certain value to the same variable e.g. for integer variable, x=x+5 or for string variable, test=test+"additional". We were trying to achieve the same thing using PowerAutomate. However, while doing this using Set Variable action, we got an error saying "Self-reference is not supported when … Continue reading PowerAutomate: Self-reference is not supported when updating the value of variable

D365 CE: Error while activating BPF “An attribute with the specified name already exists. Exception Message: Column names in each table must be unique. Column name ‘stageid’ in table ‘EntityName’ is specified more than once.”

Recently, while activating a Business Process Flow, we got below error: "An attribute with the specified name already exists. Exception Message: Column names in each table must be unique. Column name 'stageid' in table 'EntityName' is specified more than once." While checking the entity metadata for which we had created BPF, we found that Business … Continue reading D365 CE: Error while activating BPF “An attribute with the specified name already exists. Exception Message: Column names in each table must be unique. Column name ‘stageid’ in table ‘EntityName’ is specified more than once.”

D365 CE: Get Logged in User’s Security Roles using JavaScript

Many times we come across requirements such as show/hide ribbon buttons based on logged in user's security role. Earlier, we used to get security roles of logged in user at client side using Xrm.Utility.getGlobalContext().userSettings.securityRoles which used to return array of GUID value of each security role. Now that it's deprecated, we can use Xrm.Utility.getGlobalContext().userSettings.roles which … Continue reading D365 CE: Get Logged in User’s Security Roles using JavaScript

D365 CE: Show/Hide and Enable/Disable same field placed in multiple tabs using JavaScript

We often put the same fields in different tabs based on business requirements. To Hide/Show such fields we need to use below script: var formContext = executionContext.getFormContext(); formContext.getAttribute("fieldName").controls.forEach( function (control, i) { ¬† ¬† ¬†control.setVisible(false/true); }); Similarly, to Enable/Disable such fields we need to use below script: formContext.getAttribute("fieldName").controls.forEach( function (control, i) { control.setDisabled(false/true); }); Without … Continue reading D365 CE: Show/Hide and Enable/Disable same field placed in multiple tabs using JavaScript