Blog

  • Preview -Split Audience in the Customer Journey by Percentage/Number

    In the latest update from Microsoft, a highly anticipated feature has been introduced: the ability to split the audience in a journey based on either a percentage or a specific number of customers. This enhancement is a game-changer for many clients, as it allows them to efficiently target specific customer segments within a single journey. For example, businesses can now easily offer “First 1000 Coupons” to the first 1,000 customers without needing to create multiple journeys. Previously, marketers had to rely on branching using attributes, if/then conditions, or trigger activation checks within the journey. These methods, while functional, could sometimes cause delays in processing. This new feature streamlines the process, ensuring faster and more effective campaign execution.

    To use this feature in the customer journey you need to select “Audience split(preview)” tile in the journey as below –

    Then you will get the below screen to split the audience based on percentage as below-

    As you can see, the current option to “Split audience by” only allows for selection by percentage, with no option to split by a specific number. This limitation might be due to the feature being in preview, meaning it’s still in the testing phase and not fully rolled out. It’s possible that the ability to split the audience by a specific number will be included in future updates as Microsoft continues to refine and expand this feature. Keep an eye out for upcoming releases, where this capability may become available.

    Let’s dive into the “Split Audience by Percentage” feature. With this capability, you have the flexibility to divide your audience between branches based on the percentage you specify. If you want to split the audience equally, it’s as simple as clicking the “Add branch” button and then selecting the “Equalize” option. This automatically distributes the audience evenly across the branches.

    However, if you have a specific plan in mind, you can manually adjust the percentages to match your strategy. Once your audience is divided, you can assign different activities to each branch. For instance, in my example, I’ve chosen to send 50% of the audience an email (Email 1) with one type of content, while the remaining 50% receives a different email (Email 2) with other content. This level of customization allows for more targeted and effective campaigns, tailored to different segments of your audience.

    This feature also provides valuable insights into how different segments of your audience respond to specific actions within each branch. By comparing these reactions, organizations can optimize their strategies, ultimately driving better sales performance.

    For details around the Split Audience by Number you may go through below blog –

    https://learn.microsoft.com/en-us/dynamics365/release-plan/2024wave1/customer-insights/dynamics365-customer-insights-journeys/provide-varied-experiences-one-journey-using-journey-split-tiles#feature-details

    Hope to see many such interesting features in future !!

  • Preview – Plugin Monitoring through Dataverse Accelerator App

    I was exploring the Dataverse Accelerator App, and I came across this preview feature which explains about the plugin monitoring through Dataverse Accelerator App.

    Earlier in my environment I only had 2 options as below –

    Create Instant Plugins and Create Automated Plugin

    So in order to get the Plugin Monitoring option you may need to update the Dataverse Accelerator app through – https://admin.powerplatform.microsoft.com/.

    Select your environment and then Navigate to Dynamics 365 Apps.

    You may see the option as Update available besides the “Dataverse Accelerator App”. Click on it and install.

    Installation may take few minutes to complete. Once it is complete you see Plugin Monitoring option in the app as below –

    So when you click on the Plugin Monitoring above you will see the Plugin Traces screen as below –

    Earlier in order to view the Plugin Traces we would either have to navigate through Settings > Plugin Trace Logs in the old UI (Web UI) or use Plugin Trace Viewer in XrmToolbox.

    But now from this latest Plugin Monitoring option in Dataverse Accelerator App we get the new modern UI look to monitor the Plugin Traces.

    Also from above if we click on the Settings Icon in Plugin Monitoring page we will get the option to enable/disable the trace logs and no need to navigate to System Settings.

    Also when we select any particular trace log record we see the information of Message body and Exception details in the right hand side pop-out as below-

    In addition to this, we are also able to see the Status column which represents “Success” or Failure of the operation. Also we have the option to Filter the rows as below

    It becomes more handy to filter out the plugins using the available filter options.

    (Image added from docs.microsoft.com)

    Using this inbuilt modern UI for monitoring the plugins it will become more handy option for Administrators to monitor the failure and verify the logs.

    As it is a preview feature, we may expect some more enhancements in the feature in coming time.

    For details like Privileges required, or any FAQ’s on this preview topic you may also follow below link –

    https://learn.microsoft.com/en-us/power-apps/maker/data-platform/dataverse-accelerator/plugin-monitoring

    Hope this becomes handy feature in coming days !!

  • Tip – Setting Default Time Zone for Real-time Journeys in Customer Insights- Journeys

    Whenever we create a new Real-time journey in Dataverse, we see the Default time zone set to “GMT Coordinate Universal Time” as below. This is the default behavior of journeys. And then when we need to run the journey in specific time zone we change the value of the time zone dropdown to specific time zone and then publish the journey.

    Have seen couple of times if we don’t change the journey time as per the selected time zone and publish the journey then we will have to wait for the corresponding GMT time to start the journey.

    So in-order to address this thing we have option to select the Default settings for the time zone by following below steps.

    Navigate to Settings > Journey Settings as below.

    You will get the below page opened, on click of Journey settings where we will get the dropdown for time zone type as below-

    So as you can see above we have 2 options here

    Option 1 – As specific timezone

    When we select this we get the option to select a default time zone which we want to be applicable for all the journey records created after enabling this setting.

    So after selecting this option we need to select the Default timezone which we want to apply for new journeys as below-

    After enabling this setting the new journey records will populate the same time zone value as selected above.

    Option 2- The time zone of the user who creates the journey

    When we select this option the default time zone on the journey is set as per the time zone of the user creating the journey. So if you want to apply user’s time zone to the journeys created by them, we can have this setting enabled as below.

    When we enable any of the above options as per the business need, we will start seeing the changes in the default time zone set on the new journey records as below-

    Note– This setting will work for the new journey records created after enabling the settings.

    Hope this setting is useful for people like me who don’t want to manually change the time zone every time they select a new journey record.

  • Tip – Secure Input/Output Data in Power Automate Run History

    Recently one of my colleague asked me about can we hide the sensitive input/output data which we can see in the Power Automate Run History ? This made me search and get the quick response of the available option to achieve it. (which I was really surprised I was not using)

    So below is a sample Power Automate which i created to showcase this. I created a Instant flow “Run Test Flow” with Input Parameter ”Get Value” and then we will use this value to create a record in table “Custom Test A”

    Usually the flow run history of one of the sample run of above flow will look as below-

    As you can see you will be able to see the value entered in the field “Get Value” as “Value entered by sid”.

    Now we will enable the Secure Input/Output Settings for both the steps added in the above flow considering it to be sensitive information by selecting the steps and click on Settings from ellipsis as below.

    After enabling it, we will again run the flow and then open the latest run of the flow. We will see the below screen –

    So now you can see that the entered value and the contents in the steps were hidden.

    So using above setting we can hide the sensitive data which we don’t want to show in the Flow Run history.

    Note- The data is hidden only for the flow runs after the setting is enabled and not for the past runs where the setting was disabled.

    Hope this helps !!

  • Tip-Generate PDFs using Fonts through Azure Function using PDFsharp FontResolver and C#

    Recently we had a requirement to change our existing console application to Azure function. The challenging part here was to use the specific fonts which we had installed in the server machine to run the console application and generate the PDF file in desired Font Format.

    We created Azure Function of Timer type to run every 10 minutes and copy the supported code in Azure function. Problem was how to reference the specific Fonts in Azure functions.

    In order to make the Fonts available in Azure function we uploaded the required Font files of “.ttf” type as you in the Azure Blob container named “sidcon1” as shown below-

    After that we created the Environment Variable “BlobConnectionString” in the Azure Function to store the connection string to get the font file as below-

    After adding that now we need to set the GlobalFontSettings.FontResolver with the FontResolver object as documented here – https://www.pdfsharp.net/wiki/FontResolver-sample.ashx?AspxAutoDetectCookieSupport=1

    So we just added below line in the code along with implementation of FontResolver class.

     var fontResolver = new FontResolver(connectionString, templateBlobContainerName);
     GlobalFontSettings.FontResolver = fontResolver;

    One most important thing here I saw was, as the code referenced the FontResolver multiple times we started getting below error in the Azure Functions –

    FontResolver – ‘Must not change font resolver after is was once used.’

    So after spending couple of hours with the error we figure our that using C# lock mechanism we could get the object set only once, so we added below code to set the GlobalFontSettings as below which ensured that FontResolver was assigned value only once.

    (In above code for testing purpose the timer trigger was set to run every 2 minutes)

    Below I will add the FontResolver class which I had created in my application to get and set the Fonts from Azure Blob containers while generating PDF

    using Azure.Storage.Blobs;
    using PdfSharp.Fonts;
    using System;
    using System.IO;
    
    namespace TrialFunctionApp
    {
        // Custom FontResolver implementation
        public class FontResolver : IFontResolver
        {
            string connectionString = string.Empty;
            string containerName = string.Empty;
            public FontResolver(string connectionstring,string containername)
            {
                connectionString = connectionstring ?? string.Empty;
                containerName = containername ?? string.Empty;
            }
            public byte[] GetFont(string faceName)
            {
                // This implementation provides Arial font. You can modify it to load your desired font.
                if (faceName.Contains("Sarabun"))
                {
                    return FontHelper.GetFont(connectionString,containerName, "Sarabun-Bold.ttf");
                }
               
                else
                {
                    return null;
                }
            }
    
            public FontResolverInfo ResolveTypeface(string familyName, bool isBold, bool isItalic)
            {
                return new FontResolverInfo(familyName,isBold,isItalic);
            }
    
    
        }
    
        // Helper class to load font data
        public static class FontHelper
        {
            public static byte[] GetFont(string connectionString, string containerName, string fontFileName)
            {
                // Create BlobServiceClient using the connection string
                BlobServiceClient blobServiceClient = new BlobServiceClient(connectionString);
    
                // Get a reference to the container
                BlobContainerClient containerClient = blobServiceClient.GetBlobContainerClient(containerName);
    
                // Get a reference to the font file blob
                BlobClient blobClient = containerClient.GetBlobClient(fontFileName);
    
                // Download the font file to a memory stream
                MemoryStream memoryStream = new MemoryStream();
                blobClient.DownloadTo(memoryStream);
    
                // Return the font data as byte array
                return memoryStream.ToArray();
            }
        }
    
    }

    The above code ensured that the Fonts were correctly referenced in the Azure functions to generate PDF file.

    The PDF generation code remains the standard code as specified by PDFsharp references as below-

    https://www.pdfsharp.net/wiki/PDFsharpSamples.ashx

    In this blog I have specifically added the Font setting part using custom FontResolver class to help others trying to meet similar requirement.

    Hope this helps !!