How to – Use Personalized page content in Dynamics 365 Marketing

Continuing our previous post –, in this post we’d see the personalized page content works across the pages in the site.

Suppose we have the following embedded marketing form, submitted by the user with Remember Me checked (required for Personalized Page as well as Prefill to work)

Next time when the user visits the page, using the Personalized Page’s Script, we can have this value fetched from the cookie as shown below.

Here we can use the same personalized page script on other pages in the same authenticated domain/website to retrieve the values from the cookie.

For that, we just need to have the website’s div tag to be placed on that page, as shown below. We can get from that from the website record created and it will track the visit as well.


Hope it helps..


How to – Hide, Submit and validation in Dynamics 365 Marketing Form

Continuing our previous post on setting hidden field’s value using JavaScript in Embedded Marketing Form,

below are a few more points that could help –

  • To hide the Marketing form on the host page – we can use afterFormRender
  • To submit the Marketing form on the host page –

  • If we are setting a non-existing value for an option set field in the formSubmit event, it will be treated as blank before submission and the blank value will be passed. However if the field is Required then validation will kick in and the form will not get submitted.

Get more details – Extend marketing form using code

Hope it helps..


Dynamics CRM Integration with Azure Service Bus–Part 1

Technology Notes

Last month, one of my friend called me and asked me if I can help him integrating Dynamics CRM with an on-premises line of business (LOB) application using Azure Service Bus. He was a SharePoint expert, with reasonable experience of Dynamics CRM and Azure Service Bus also and he had to develop a POC for his client to win a project. By then I didn’t have any experience with Microsoft Azure. So, I looked it as an opportunity for me to learn something new, the Microsoft Azure Service Bus. I spent few days studying and watching concepts and demos regarding Microsoft Azure, Azure Service Bus and Dynamics CRM-Azure integration. Eventually, we both started working on the project. The project had few other challenges too, but mainly I learned enough about Azure Service Bus and Dynamics CRM integration while working on this project. In this two part series of blog post…

View original post 1,114 more words

[Exploration] Dynamics CRM Azure-aware plug-in + Azure Queue + Power Automate

Temmy Wahyu Raharjo

Do you know the Azure-aware plugin? In short, we can create a simple plugin that invokes Azure Service Bus that enables us to do the Publisher-Subscriber model. In this blog post, we will try to makeAzure Service Bus, Dynamics CRM Service Endpoint, andCRM Pluginfor creating the queue. While for the processing part (subscriber), we will createCloud Flowthat will listen to the queue + insert a row on the google sheet.

Creating Azure Service Bus

You can go to your >Service Bus> click theCreatebutton. On that page, you can fill in theSubscription, create/select theResource group, fill theNamespace, set theLocation, and set thePricing tier(I choose Basic for the demonstration purpose which is the cheapest tier). After that, you can hit theReview+createbutton and proceed to create the resource.


View original post 855 more words

Two way communication between CRM and Azure Service bus

Srikanth Alluri

This is the next level of my previous post on Azure service bus integration with CRM. If you haven’t gone through it already, I would highly recommend you to go through it first over here as whatever we are going to do here in this post is kind of an extension to my previous one.

So, in the last post, we saw how we can pass the CRM entity information to ASB (Azure Service Bus) whenever it got created/updated/any other plugin actions happened. And you must have noticed by now that it would be an asynchronous job for us, meaning CRM would be in ‘fire and forget’ mode. All it knows is it has dropped a ‘Message’ in a Queue, it doesn’t know when it got picked up and when it got processed and who picked it up etc. In some cases this might be the exact behavior we are…

View original post 1,462 more words

How to – use Dynamics 365 Marketing JavaScript API to set hidden field’s value

Dynamics Marketing JavaScript API is only available for the marketing form hosted as Script. It is not available for forms hosted as Iframe.

More on embedding form on external page –

Add a reference to form-loader.js or load.js to access the API.

Below is our form with a hidden field in it.

Based on the current living situation (drop down), we want to set the value of the Financially Capable field (bool) – the hidden field’s value as either True or False.

For this, we have added the below script, in the formSubmit event.

formSubmit triggers on form submit before the form submission is sent to the server.

Check all the events here –

The script – Get the id of the element through browser’s developer tools.

Hope it helps..

  // Extending Marketing form with code 
        // formSubmit - Triggers on form submit before the form submission is sent to the server.
        MsCrmMkt.MsCrmFormLoader.on('formSubmit', function (event) {
            // get the id of the elements through developer tools of the browser
            // based on selected current living situation (optionset)
            if (document.getElementById('deb110aa-e266-ed11-9561-000d3ae090c0') != null) {
                var selectedCurrentLivingValue = document.getElementById('deb110aa-e266-ed11-9561-000d3ae090c0').value;
                if (selectedCurrentLivingValue == 881990000) {
                    // set the value of Financially Capable field (boolean)- true / false
                    document.getElementById('dcc46e64-2867-ed11-9561-000d3ae090c0').value = "1";
                else {
                    document.getElementById('dcc46e64-2867-ed11-9561-000d3ae090c0').value = "0";
%d bloggers like this: