Many of us use the Microsoft Dynamics 365 Developer Toolkit for plugin development. This tool helps developers avoid manual tasks and helps them focus on implementing the business logic. Unfortunately, this tool is no longer working since the switch from Regional Discovery service to the Global Discovery service. Actually, the error “FCB ‘EnableRegionalDisco’ is disabled” is generated when connecting to the Dataverse environment.
On this blog, I will propose a workaround to solve this problem and continue to use the tool for the development and maintenance of your plugins by connecting to a Dataverse environment using the Global Discovery Service.

Before starting, this is the configuration used on my personal environment. Indeed, I use the following versions:
- Plug-in Registration Tool version 9.0.2.7
- Crm Sdk Bin (CoreTools) version 9.0.2.6

You can download the same versions of the SDK tools using the following PowerShell script:
Also, we will need the latest version of the SDK. The PowerShell script to use is shared on the docs: https://docs.microsoft.com/en-us/powerapps/developer/data-platform/download-tools-nuget#download-tools-using-powershell
To make it easier to follow the steps, below are the two directories used:

Now it is time to go to the folder that corresponds to the Visual Studio extension of the Microsoft Dynamics 365 Developer Toolkit. In my case, this is the path used:
C:\Users\mehdi.elamri\AppData\Local\Microsoft\VisualStudio\16.0_fcaab508\Extensions\u14kvtmh.ce5

Then, we need to replace the following Dll files of the extension by those of the last version of the registration tool plugin:
- Microsoft.Crm.Sdk.Proxy.dll
- Microsoft.Xrm.Sdk.dll
- Microsoft.Xrm.Tooling.Connector.dll
- Microsoft.Xrm.Tooling.CrmConnectControl.dll
- Microsoft.Xrm.Tooling.Ui.Styles.dll

After re-starting Visual Studio, the tool should connect smoothly to a Dataverse environment using the Global Discovery Service:


Be prepared, we are halfway there. Indeed, after being able to connect to the CRM using the Global Discovery Service. An error is generated when deploying a plugin: “Could not load file or assembly ”CrmLibraries, Version=8.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35 or one of its dependencies. The located assembly’s manifest definition does not match the assembly reference.“

To resolve this issue, we need to replace the following Dll files of the Plugin registration tool used in the tool path by those of a version 8 of the registration tool:
- CrmLibraries.dll
- Microsoft.Xrm.Sdk.dll
You can download the version 8 on this link: https://www.microsoft.com/en-us/download/details.aspx?id=50032

Finally, after all this manipulation. I can manage to connect to a Dataverse environment and deploy my plugins with the tool while using the global discovery service. Finally, the process shared on this blog may not work for you. It depends strongly on the version of the SDK used. I highly recommend using the same version I used.

Hope it helps…
Edit: For the moment, only the connection and the deployment are functional. Indeed, the Entity class generation and the creation of a new plugin is not functional for the moment. I will edit this Blog as I can find fixes. The next step will be to fix the error generated when creating a new plugin.
Hello:
One option may be to see if you can set SkipDiscovery=true if you know the URL you are connecting to.
https://docs.microsoft.com/en-us/powerapps/developer/data-platform/xrm-tooling/use-connection-strings-xrm-tooling-connect
This can be configured in the PRT file PluginRegistration.exe.config with this entry
LikeLiked by 1 person
It stripped out my XML so add open and closing chevrons to these
appSettings
add key=”SkipDiscovery” value=”true”
appSettings
LikeLike
Hello,
Thank you so mush for your feedback !! I don’t know if it is possible to add this configuration to the PluginRegistration.exe.config..
Did you manage to do this?
Thank you
LikeLike
Hi Mehdi,
Thanks for this post, very useful, followed the steps and it works as you explained.
Thanks
LikeLiked by 1 person
Hi Kokulan,
I’m glad it worked out for you. For now, the solution is just a workaround. There are still a lot of bugs to fix…For example, I can’t generate early bound entities…Does it work for you?
LikeLiked by 1 person
No creating early bound class from CRM Explorer pane fails as it uses the tooling connector from the folder paths we set. I do not use early bound classes much but we can generate from command line and add it to the project manually so its not a showstopper I think.
LikeLiked by 1 person
Also, the creation of a new plugin is not yet functional. I managed to fix that… I will update this blog soon…
LikeLiked by 1 person
Hello Mehdi,
Did you find a solution to create new plugins with the toolkit?
LikeLiked by 1 person
Yes, I will update the blog ASAP.
LikeLiked by 1 person
thanks for the tip Mehdi unfortunately coping the additional dll didnt make any difference. I guess I will have to revert to using the standalone plugin registration tool and manually deploying of JS until I can spend some more time debugging this.
LikeLiked by 1 person
Can you share the information about enabling creation of a new plugin?
LikeLike
Thanks really helpful blog post. The post did allow me to login and select the organisation. However, once the organisation was selected it gets stuck on the connect to CRM loading screen. Any ideas?
I really like using the developer toolkit its just been a constant battle ever since it was first release to get it to play nicely and work with later versions of Visual Studio.
LikeLike
Hello Antony,
Maybe you need also to copy Microsoft.Rest.ClientRuntime.dll.
Please refer to Jupek’s answer in this thread: https://community.dynamics.com/crm/f/microsoft-dynamics-crm-forum/426903/software-developer-toolkit-and-deprecation-of-the-regional-discovery-service
Good Luck !
LikeLike
Thanks Mehdi I tried but still have the same issue. Can I confirm what DLL’s you copy is it the ones from the latest SDK on the MS site powershell or the specific version you download in the blog. I maybe misunderstanding but it seems your downloading the same thing twice?
LikeLiked by 1 person
ok so Ive got little bit further than before I get an error “Target invocation error” and it freezes but it does say “Connection to Microsoft Common Data Service Complete”
LikeLiked by 1 person
Hi,
The new version of the tool has just been released. Software Developer Toolkit is now Power Platform Tools: https://marketplace.visualstudio.com/items?itemName=microsoft-IsvExpTools.PowerPlatformTools
Docs: https://docs.microsoft.com/en-gb/powerapps/developer/data-platform/tools/devtools-install
LikeLike