Skip to main content

Posts

Showing posts from 2022

Embed PowerBI Report to CRM Form with filters using Power BI Embedder

 Introduction: You can now add your Power BI report to Dynamics CRM form and also add filters to the report easily with Power BI embedder tool of XRM Toolbox. Explanation: Download Power BI Embedder in XRM Toolbox and connect to your organization Chose the D365 CRM Entity, Form, Tab, Section where you want to embed the Report. In formatting change the rowspan to ensure the report fits on the page as needed. In Power BI Config add the Group ID, Report ID and Page you will find this on the report URL in Power BI https://app.powerbi.com/groups/ 98765ty7-nju7-567y-vft5-12345678yytr /reports/ 4fb4555-9d54-yyff-9987-f49999999999 / ReportSection5afdbb2222228c4221 Group ID- Yellow Report ID- Red Page - Green click on the filter checkbox to add filter PBI table - Name of table in Power BI that contains the field to be filtered  PBI Column - name of field to be filtered as per Power BI CDS Field- select the CDS field from dropdown, this will be the equal to value of filter. Note that PBI Table a

Export To File from Power BI with Filters

Introduction:  In this blog we will understand the action "Export to File from PowerBI report". Power BI has options to Export the Report in PPT or PDF format, however if you need the Report to be uploaded to SharePoint or send as email using a flow, you can use the  Export to File from PowerBI report action in power automate. Explanation: The Export To File for Power BI Reports has below parameters- Workspace- In dropdown you will see the workspace options, if you are the owner of report or if report is shared with you, you will see the report in "My workspace". Report- Select the report from the dropdown, it will show all reports that you have access to in the workspace Export Format can be PDF, PPTX or PNG You can add further details like Bookmark, locale, etc. Another main parameter is Filter- if the main report is not filtered but you need the exported one to be based on a filter you can add the filter as Table/fieldname eq 'value' Please Note that the

Add To Time Action in Power Automate

  Introduction- In this blog we will understand the "Add to time" action of power automate/ cloud flow. Explanation- Add to time will add a integer number of a specified unit of time to the timestamp passed. Example- We can add 1 day/ second/minute/year/month to the passed time stamp. Syntax- addToTime('timestamp',interval,'timeUnit','dateFormat') Date format is optional. Output-  Note- This action adds the mentioned value however it does not validate the output date. There is a possibility of the output being a non existent date time value.

Date and Time expressions in Power Automate

  Introduction- In this blog we will walk through all date and time expressions in power automate / cloud flow Explanation- For examples we have considered input as UTC. Format is optional in most of the expressions.

Merge Action in Plugin

   Introduction- In this blog we will understand the Action Merge from a Plugin (SDK message) perspective. Problem Statement: 1) We want to retrieve data once the Merge is performed on two records. 2) We want to merge 2 records using a plugin (C# code). Solution: For the first statement, We shall be triggering a plugin on the message "Merge". While using the plugin registration tool, select message as Merge. Below code is to be used-   if ( context . InputParameters . Contains ( "Target" ) && context . InputParameters . Contains [ "Target" ] is EntityReference ) {     EntityReference Master = ( EntityReference ) context . InputParameters [ "Target" ];     Guid duplicate = ( Guid ) context . InputParameters [ "SubordinateId" ];  } For the second problem statement, we will invoke/ use the Merge method. Below is the code-       var target = new EntityReference ();       target . Id = Recordid ; //master record id       ta

Merge Action in Cloud Flow

  Introduction- In this blog we will understand the Trigger and Action available for Merge Action in Power automate (Cloud Flow). Problem Statement: 1) We want to update a field once the Merge is performed on two records. 2) We want to merge 2 records using flow. Solution: For the first statement, we will be triggering a flow on Merge Action. Note- Table name will differ as per the requirement, here for example I have considered Lead. The output of the trigger is a JSON body that needs to be parsed, below is the schema.      { "type" :  "object" ,      "properties" : {          "InputParameters" : {              "type" :  "object" ,              "properties" : {                  "Target" : {                      "type" :  "object" ,                      "properties" : {                          "Id" : {   "type" :  "string" },