Setting up Developer Toolkit for VS2019 with Core Assemblies(9.0)

Visual Studio 2019 is now available for developers and dynamics 365 CE version 9.x Software Development Kit (SDK) too. However Dynamics 365 Developer Toolkit only supports for Visual Studio 2012, 2013, 2015 and it uses Dynamics 365 CE SDK 8.x assemblies and tools.

This article to make Dynamics 365 Developer Toolkit workable for VS 2019 and to prevent some common issues when setting up Plugin Library project to work with Dynamics 365 CE version 9.x core assemblies.

Special thanks to Sucheet Chavan for sharing useful information to the article.

Setting up Developer Toolkit for VS2019

Although Dynamics 365 Developer Toolkit doesn’t support after Visual Studio 2015, developers perform few workarounds to use the extension with VS2017. Following article is still valid for VS2019 with one change to the extension.

Continue reading “Setting up Developer Toolkit for VS2019 with Core Assemblies(9.0)”
Advertisement

Sending Dynamics CRM Execution Context to Azure Service Bus

Nowadays different software systems are connected with each other in different ways to exchange data and services among them. Also maintaining cloud spaces for hosting and using cloud services have become very popular in the industry. Dynamics CRM 2016 can be hosted as on premise and it’s available as Online as well and it supports exposing its execution context to Microsoft Azure Service Bus to easily communicate with the other applications, services or devices connecting from anywhere. Dynamics CRM plugin registration tool can make Azure aware the executions in CRM.

Service-Bus-Fanout1

Assume that there’s a need to update some other system on a change of data in an entity in CRM. One approach is to bring changed data in to an online location and the other system to read those data and update its data stores accordingly. Azure service bus is a cloud service that maintains queues and topics to act as intermediate location between two systems. Specialty is that; Dynamics CRM can automatically send data with its context in an event available in Dynamics CRM such as Create, Update, Delete etc…

Azure Service Bus

Azure service Bus is a generic, cloud based messaging system for connecting services, applications and devices from anywhere. It supports two types of communication models such as Queues and Topics.

Understand Azure Service Bus using following resources; Continue reading “Sending Dynamics CRM Execution Context to Azure Service Bus”

Team Foundation Service

Maintaining a Version Control System is an additional overhead for a software development team and its further difficult when the team members are connecting from different regions of the world from different networks. Some development teams use different tools with different programming languages and maintaining different types of source controls will be a challenge. Most of the time project managers track development progress from some other system and team members should log in to that system at the end of the day and log whatever the things they have done.

Microsoft provides Team Foundation Service for Source Controlling facilities as well as project management capabilities with Scrum templates.
TFS Preview

http://tfspreview.com/

Team Foundation Service can be accessible from anywhere with IDEs like visual studio and eclipse. Development teams can be start working on their solution without thinking of managing infrastructure setup and maintainance in the their premises. It mainly provides following areas of services;

Continue reading “Team Foundation Service”

Debugging a Plug-in

Plugin is a .NET assembly that can be used to intercept events generated from the CRM system to perform a variety of actions. Some common plug-ins will perform a complicated update routine on CRM entities and\or attributes when it might be impractical to use Javascript or Workflow.

Not like in most of the other developments, in Plugins developers have to debug the CRM plugin code at the time of running the application. Developers writing the plugin code inside the plugin and some times the logic can be write in a seperate assembly and from the plugin code it can be invoked. When writing the whole logic inside the plugin is little complex to test the plugin logic by debugging the plugin as it executes from the application itself in a given event such as create an entity, update or delete.

There are two ways of debugging a CRM plugin as follows,
[1] Attaching the debugger to the w3p.exe process
[2] Forcing the add-in to call the debugger

Demonstration
A plugin has written targeting Account entities as follows and a step has registered to be fired on Account entity’s Create step.
Continue reading “Debugging a Plug-in”

Binding a Dictionary to a Drop Down List

Binding data from a Dictionary is not so challenging as “Key” and “Value” pairs can be used for the drop down list properties. Following code samples show the results after assigning data source to the drop down list.

Before

Dictionary genderDictionary = new Dictionary();
genderDictionary.Add(1, "Male");
genderDictionary.Add(2, "Female");
genderDictionary.Add(3, "Transgender");

this.ddlGender.DataSource = genderDictionary;
this.ddlGender.DataBind();

Before Assign Key Value Pair

Continue reading “Binding a Dictionary to a Drop Down List”

Register all Assemblies in GAC at once

GACUTIL is the tool available to register assemblies to the GAC.
Eg.g gacutil.exe /i C:\MyAssemblies\test1.dll
But if there are more than one assemblies to be registered, use following in the command prompt
FOR %a IN (C:\MyAssemblies\*.dll) DO GACUTIL /i %a


http://msdn.microsoft.com/en-us/library/ex0ss12c(v=vs.80).aspx

Find public key token for a .NET DLL or assembly

You can get the public key token by using following command. Keep in mind that the dll should be a “Strongly Typed” one.


c:\Program Files (x86)\Microsoft Visual Studio 10.0\VC>sn -T C:\sdk\Microsoft.Xr
m.Sdk.dll


Microsoft (R) .NET Framework Strong Name Utility  Version 4.0.30319.1
Copyright (c) Microsoft Corporation.  All rights reserved.


Public key token is 31bf3856ad364e35