Discord channel

I wanted to set up a global group chat for people within the Microsoft Dynamics Development space.  I use Slack at work, but the problem with that is the closed invite system.  It is difficult setting up Slack to allow people from different teams/companies if they have different email addresses.

Discord is traditionally a gaming chat system that works very similar to Slack, but is free, and with an appropriate Link, allows anyone to join specific channels.

So, I thought I would give it ago.  If you are reading this blog, then feel free to use the link below and join Microsoft Dynamics Discord channel and introduce yourself.

Microsoft Dynamics Discord Channel

 

My utilities are now on the Visual Studio Marketplace

Just a quick update to say that all of my Visual Studio extensions are now on the Microsoft Visual Studio Marketplace, and are available to download and install direct from Visual Studio.

Visual Studio Marketplace

Simply go into the Tools menu and choose Extensions and Updates, select Online and search for me, James Hall.  My extensions are the top two in the list.

In theory, if you install them this way, you should get notified of when I update them.

Dynamics Documentation PowerShell Downloader

A common issue I am always faced with these days is the ability to have some Dynamics CRM / D365 Documentation, offline.  I am always a fan of PDF documentation that I can carry with me on my iPad, and since Microsoft stopped providing the usual CHM files with the traditional SDK’s, I have been at a bit of a loss.

With the advent of the new Documentation site that Microsoft have moved everything to, they now provide you with a handy option to download chunks of the documentation in PDF format.  Brilliant.

However, I don’t want to have to go through all of the sections to manually download the documents, and of course, what if, and how often do you need to do this to keep your documentation up to date.

Well, stand by for the amazing Dynamics Documentation PowerShell Downloader.  It really is quite simple, and feel free to add as many other documents as you wish to the script.  You can of course also modify it to save it to a different folder by changing the folder at the top of the script.  This goes hand in hand with the Dev Tools downloader that I blogged about previously.  Although the previous Script was provided by Microsoft, this one is all me 🙂


# Change the variable folder to the location you wish to save the Documentation to
$folder = "c:\DevTools\Documentation"

# Add the documents you wish to download below, in the format "filename" = "URL";
$documents = @{ "Customer Engagement Admin Guide.pdf" = "https://docs.microsoft.com/en-gb/dynamics365/customer-engagement/opbuildpdf/admin/TOC.pdf?branch=live";
                "Customer Engagement Customisation Guide.pdf" = "https://docs.microsoft.com/en-gb/dynamics365/customer-engagement/opbuildpdf/customize/TOC.pdf?branch=live";
                "Customer Engagement Developer Guide.pdf" = "https://docs.microsoft.com/en-gb/dynamics365/customer-engagement/opbuildpdf/developer/TOC.pdf?branch=live";
                "Customer Service User Guide.pdf" = "https://docs.microsoft.com/en-gb/dynamics365/customer-engagement/opbuildpdf/customer-service/TOC.pdf?branch=live";
                "Unified Service Desk.pdf" = "https://docs.microsoft.com/en-gb/dynamics365/customer-engagement/opbuildpdf/unified-service-desk/TOC.pdf?branch=live";
                "Customer Engagement Portals Guide.pdf" = "https://docs.microsoft.com/en-gb/dynamics365/customer-engagement/opbuildpdf/portals/TOC.pdf?branch=live";
                "Customer Engagement Field Service Guide.pdf" = "https://docs.microsoft.com/en-gb/dynamics365/customer-engagement/opbuildpdf/field-service/TOC.pdf?branch=live";
                }


md $folder -ErrorAction Ignore
cd $folder

foreach ($h in $documents.Keys) {
    Write-Host "Downloading ${h}"
    Invoke-WebRequest $documents.Item($h) -OutFile $h
}

 

Diagnostics and Information page, a reminder

As I keep forgetting that these pages exist, I am re-blogging the following information as its very useful :), and maybe I will eventually remember these URL’s.

Diagnostics
 
http://<ServerName>/<OrganisationName>/tools/diagnostics/diag.aspx
 
Debug Information (on premise only)
 
http://<ServerName>/<OrganisationName/home/home_debug.aspx

Here are some bookmarklets that you can drag to your bookmarks bar which should allow you to just click on them while on a CRM instance, and the appropriate pages should pop up.

Dynamics 365 SDK tools – Powershell Downloader from Microsoft.

Since Microsoft have now removed the standalone SDK download, instead offering it via NuGet packages, they have also released a handy PowerShell script that allows you to keep them updated on your machine. Very useful.

CRM Utilities for Visual Studio – Update to menus, and class generation options

Today I have released an update to the CRM Utilities for Visual Studio 2017 extension.

New features:

Reorganised the menu structure so that the Generate Class options are now grouped together.

Generate Class options menu to allow a custom namespace and class name to be used when generating the class files to represent the Dynamics Entities.

Redesigned the Connection dialog to make it look better, and to include a hyperlink to the instruction pages on this blog.

 

Download
Please note this feature is only available in the Visual Studio 2017 version. This version may still install on VS2015, although I have not personally tested it.

DevOps for Dynamics 365

DevOps (a clipped compound of “development” and “operations”) is a software development and delivery process that emphasizes communication and collaboration between product management, software development, and operations professionals.

DevOps – The new buzzword.

Although I have never actually tried any of the following (but it is on my list of things to do), here are a collection of resources for applying the concept of Continuous Integration and Delivery for Microsoft Dynamics 365.

Continue reading “DevOps for Dynamics 365”

CRM Utilities for Visual Studio – Generating Entity Classes

Most CRM Developers either use, or have at least heard of CrmSvcUtil for generating early bound classes for developing code and using the resulting classes to manipulate CRM data.  I personally do not like working with early bound entities as the resulting class files are huge, and I personally prefer working with the standard Entity Framework for creating and updating entities, and for Linq queries.

Often, I use some helper class libraries that I can use to represent the custom entity names and attributes, so that they can be referenced in code and provide a degree of separation from the actual Schema names and to make code easier to write, and support Intelli-sense.

Something like the code sample below:


public static class Contact
{
    public static const string EntityName = "contact";
    public static const string Name = "fullname";
}

This would then allow you to do the following:

public void createContact()
{
    Entity contact = new Entity(Contact.EntityName);
    contact[Contact.Name] = "Joe Blogs";
    service.Create(contact);
}

I was offered a suggestion by a fellow developer that wouldn’t it be good if my CRM Utilities for Visual Studio allowed you to generate this kind of Class file automatically.  Well, I thought it was a brilliant idea, and so thanks to the wonderful gentleman  of XRTSoft, here it is.

Its split into two options, one to generate classes for your Custom Entities, and one to do the Standard CRM entities.

The resulting file will look something like this:

Notice that for each Entity, it will add the Logical Name, Primary ID Attribute, and the Primary Name Attribute as standard, and then all of the attributes as well.  It will also add sub classes for any Option Sets to allow you to reference specific Option Set Values without having to look them up in CRM.

 

Download
Please note this feature is only available in the Visual Studio 2017 version. This version may still install on VS2015, although I have not personally tested it.