Increasing Email Attachment Size in Dynamics 365

In Dynamics 365, the maximum size of an email attachment defaults to 5120kB, or 5MB. Let’s look at how we can increase this. First, let’s create an email message and try to add a large attachment. Go to Activties and create a new Email: Add a new attachment: Click Choose File: Let’s add a PDF file: When we try to attach it, we get the message that “The attachment is … Continue reading Increasing Email Attachment Size in Dynamics 365

Coding Multiple Plugins in One Assembly in Dynamics 365

In this post we will look at how to code 2 plugins in one assembly. This might be useful if you want to keep related pieces of code under the same code base. Let’s create a new VS project: Rename the class to Plugins: Add Microsoft.CrmSdk.CoreAssemblies through NuGet. Add the code. We will add 2 functions, Plugin1 and Plugin2: The code will write a Plugin Trace Log entry.   Sign … Continue reading Coding Multiple Plugins in One Assembly in Dynamics 365

Installing Azure CLI on Windows

Azure CLI is a command line interface (CLI) for managing resources in Azure. It can be accessed from within Azure in a browser, or by installing an app that runs in Windows, Linux and macOS. To install it on Windows, go to: https://docs.microsoft.com/en-us/cli/azure/install-azure-cli-windows?view=azure-cli-latest and click Download: Open the downloaded file: Click Accept and Install: Click Finish: Now, open PowerShell and type az login: A browser will open, and you will see … Continue reading Installing Azure CLI on Windows

How to Delete USD Cache to Recover from USD Errors

In Unified Service Desk, users may encounter errors when using USD, such as pages not loading, custom JavaScript not running etc. These errors may be a result of USD caching. To delete the USD cache, first browse out to your appdata folder in Windows Explorer. You can access appdata by typing %appdata% in the Windows Explorer navigation bar, which will take you to the user’s AppData\Roaming folder. Next, delete the following folders, which … Continue reading How to Delete USD Cache to Recover from USD Errors

XrmToolBox Error When Loading

When opening the XrmToolBox, you may come across errors such as: System.TypeLoadException: Could not load type XrmToolBox.Extensibility.Interaces.INoConnectionRequired System.IO.FileNotFoundException: Could not load file or assembly ‘WeifenLuo.WinFormsUI.Docking, Version=3.0.4.0, Culture=neutral, PublicKeyToken=5cded1a1a0a7b481’ or one of its dependencies. The system cannot find the file specified. The problem here is to do with one of the plugins that is in your XrmToolBox environment. To resolve this, go to: %appdata%\MscrmTools\XrmToolBox\Plugins\ Copy the files from the Plugins folder to … Continue reading XrmToolBox Error When Loading

Creating a WCF REST Service with Entity Framework

In this post, we will go through how to use WCF to create a REST service, also using the Entity Framework to connect to a database. We have a SQL database that holds customer information. We would like to expose this as through a REST service. In the database, we have a table called Customers that we will build our service for: Open Visual Studio and create a new WCF Service … Continue reading Creating a WCF REST Service with Entity Framework

Clear Data Parameters in Unified Service Desk

In Unified Service Desk, you may want to clear out Data Parameters as an action. Let’s say in your debugger, you have the following data parameters: If you want to clear out Account, you can do this using the ClearDataParameter action in CRM Global Manager. We can run it as: On refreshing, we can see the Account is no longer available: You can also pass, for example, name=Account#account.

Unified Service Desk Displays IE Event Window on Clicking Links

In Unified Service Desk, when clicking on links, you may encounter an issue where an Internet Explorer window is opened outside of USD, and the link looks something like http://event/?, e.g. http://event/?eventname=handleNavigateRequestCallback: This may also be preventing USD from running events and actions, so you would see unexpected behavior. To resolve this, you will need to change your IE security settings. Open up Internet Explorer and go to Internet Options: Ensure Protected … Continue reading Unified Service Desk Displays IE Event Window on Clicking Links

Calling a Dynamics 365 Workflow through JavaScript

In Dynamics 365, you may want to call a workflow directly from JavaScript. This can be achieved using the WebAPI. Let’s say we have a workflow as follows, that creates a task on the account: For the sake of the demo, we will hardcode the Workflow Id and Account Id. Copy the Workflow Id from the URL: Now create an account: Get the Id of the account: Now the code. … Continue reading Calling a Dynamics 365 Workflow through JavaScript

Check if a Dynamics 365 Field is Empty using JavaScript

To check if a Dynamics 365 field is empty, you can use: if(Xrm.Page.getAttribute(“fieldname”).getValue() == null) For example, if you wanted to check if the fax number field on the Account record is empty, first open the form and find the field name: Get the field name: Now if we add the following script to the loading of the account form: If the fax field is empty, it will display: