Friday, August 14, 2020

Don't forget to update older client applications for Dynamics 365 to the correct .NET Framework version

I lost 30 minutes this morning when trying to troubleshoot an older console app (written in 2017) which refused to connect to Dynamics 365 Customer Engagement. It was only after updating the Nuget packages for Microsoft.CrmSdk.CoreAssemblies  that I noticed that I was still building against .NET Framework 4.5.2 which is not supported anymore.


Thursday, August 13, 2020

Quick tip: SQL access to Common Data Service using Tabular Data Stream (TDS)

Recently Microsoft announced Power BI DirectQuery support (in preview) to the Common Data Service (CDS)  using Tabular Data Stream. You can also leverage this  CDS TDS endpoint within SQL Server Management Studio to write SQL queries against the CDS database. You can connect using the base url of your CDS instance and add the port 5558. To authenticate you will need to use Azure Active Directory - Password.

By default this functionality is not enabled, so you if you try to use SQL Server Management Studio you will get below exception.

As outlined on, you will need to to go the Power Platform Admin Center to switch on the TDS support.

Tuesday, August 11, 2020

Quick tip: find duplicate records in Dynamics 365 with Deduplicator plugin for XrmToolBox

 If you want to quickly scan your Dynamics 365 or CDS instance for duplicate records, take a look at the Deduplicator plugin for XrmToolbox. It provides you with the option to specify one or more fields for a specific entity as matching criteria (with option to ignore blank values, leading and trailing white space and taking into account casing) and choose which additional fields to display for the duplicate results. 

Friday, August 07, 2020

Notes on the Power Virtual Agent in a day lab

Microsoft recently also released a Power Virtual Agent in a day and I decided to give it a try. Power Virtual Agents are one of the components in the Power Platform which allow you to built intelligent chat bots without any coding or AI experience.

Since Power Virtual Agents are built on the Power Platform and the Azure Bot Framework you still have the option to extend the capabilities to suit your organisations needs.

Some notes on the Power Virtual Agent lab:
  • The creation of a virtual agent or bot is super easy and intuitive with a simple graphical interface for authoring the logic  that will drive your bots. The authoring canvas for the conversation tree has a great user experience and enables non-developers to create a powerful chatbot experience.

  • After you import the solution file, you will need to reconfigure the connections in the different Power Automate Flows - to do this you will need to use the unique name of the CDS instance - so if you have used a Dynamics CRM instance you can not use the readable name - don't forget to add the region shorthand as well.
  • If you are familiar enough with Dynamics 365 and/or Power Platform you will be able to complete the labs in a couple of hours.
  • The built-in integration with Power Automate allows you to leverage the over 250+ external services and systems so the only limit is your imagination.


Saturday, August 01, 2020

Quick tip : how to check if a Microsoft Teams channel exists in a Power Automate Flow

The new Microsoft Teams connector (Preview) in Microsoft Power Automate Flow makes Microsoft Teams automation scenarios a lot easier. The List channels action will return you a list of one or more channels for a Team. If you want to check if a channel with a specific name already exists you can  use the contains function. (For a good overview see Reference guide to using functions in expressions for Azure Logic Apps and Power Automate)

Tuesday, July 21, 2020

Setting up Omnichannel for Customer Service on an existing Dynamics 365 trial

Omnichannel for Customer Service is a Microsoft first party Dynamics 365 app which extends Dynamics 365 Customer Service which enables you to connect different channels (SMS, chat, Facebook, etc...) to your existing Dynamics 365 Customer Service App.

Listed below are  the different steps required to setup a demo scenario with chat integration for Omnichannel for Customer Service in a blank (no first party app selected upon trial setup) demo trial environment  which had customer service installed afterwards:

  1. Omnichannel for Customer Service is an add-on which requires a separate license so you first need to add this add-on in your tenant.
  2. After enabling the add-on you will need to provision Omnichannel for Customer Service by first providing data access consent and in a next step provisioning the Omnichannel for Customer Service application. The official Microsoft documentation still show how to to this from the legacy Dynamics 365 admin portal but you can do this from the new Power Platform Admin Portal as well - click the three dots and select manage for the Omnichannel for Customer Service
  3. In the separate Omnichannel for Customer Service screen you will be able to enable the different channels that you want to support. The initial setup might take a couple of hours to complete so check the same page for the status of the setup later on.
  4. Next you will need to assign the "Dynamics 365 Customer Service Digital Messaging add-on" license to the users who need have a  Omnichannel for Customer Service security role.
  5. To enable chat integration, you need to create a code snippet to embed the chat control on your website or portal. You can follow the steps on the Microsoft Omnichannel for Customer Service Administrator > Quickly configure a chat widget  which use a Customer Service Portal but you can add this chat widget to your own website as well.
  6. Support agents can use the Omnichannel for Customer Service app to interact with the users to follow up on their questions and complaints. When a new conversation comes in, it will be routed to available agents who can accept this incoming conversation. (Take a look at Understand unified routing and work distribution to understand how you automate work assignment across channels taking into account agent's capacity and skill sets)
  7. A customer agent will be able to interact with the customer using an inline chat window which is built on top of the Customer Service application which means that you will be able to leverage the full available context of the customer (existing contact info, open cases, etc ...)
There were lot of new features added to Omnichannel for Customer Service in the 2020 release wave 1 so definitely take a look at the Microsoft Business Applications Summit recording below or take a look at the Omnichannel for Customer Service sessions on Microsoft Learn.


Thursday, July 16, 2020

How to use secrets in Jupyter Notebooks with python-dotenv

It is not a good idea to embed the the secrets (credentials, keys, etc..) that you need in your Python code directly in your Jupyter Notebooks. You can store these secrets in environment variables but an alternative is using the python-dotenv library. Python-dotenv is a library that reads key-value pairs from  a .env file and adds them to environment variables.

To get started you need to install the latest version of python-dotevn and then you will need to create a .env file in the same folder as your .ipynb files.

Tip: You may not be able to create .env file directly in Windows Explorer - use the command prompt and the echo command to create this file.

You can read a key-value pair in just one line of code after you loaded the extension and the os module which provides functions to interact with the operating system.

Source code is available on