Skip to main content

Notifications

Announcements

No record found.

Microsoft Dynamics CRM (Archived)

Upgrading Visual Studio projects to use the new version of the CRM software developer toolkit

Posted on by 265

We have many Visual Studio projects which were developed with the CRM 2011 version of the software developer toolkit.
When we installed the latest version of the toolkit, we found that deployments always go badly because the crmregister file gets wiped out when you deploy and the plugins don't get registered correctly.

I've heard from the CRM Development team that "...the CRM Register file was changed substantially over the last few years, and we did not intended backward support for it."

Has anyone found a good strategy for migrating projects which were developed using the 2011 toolkit to the new toolkit? I've not found any official advice from Microsoft about this.

The most reliable option seems to be to start a new project using the 365 developer toolkit and then recreate all of your plugins manually before copying code from the old plugins into your new plugins. This seems to be a very laborious and error prone approach, especially with large projects, so I was hoping that someone had come across a better way of converting a 2011 toolkit project to a 2015/365 toolkit project.

Thanks,
Ben

*This post is locked for comments

  • Suggested answer
    MattB-MSFT Profile Picture
    MattB-MSFT on at
    RE: Upgrading Visual Studio projects to use the new version of the CRM software developer toolkit

    We were able to reproduce this and create a fix for it.  This has been posted in the update that went out today..  Please let us know if your still seeing the issue after updating your local copy of the tools.

    Also we now write out an error is there is something wrong with your register file into the CRM Diagnostics window in the toolkit.

  • Whitey@Work Profile Picture
    Whitey@Work on at
    RE: Upgrading Visual Studio projects to use the new version of the CRM software developer toolkit

    I also have the same issue again. Is there any fix for this in the works?

  • Suggested answer
    MattB-MSFT Profile Picture
    MattB-MSFT on at
    RE: Upgrading Visual Studio projects to use the new version of the CRM software developer toolkit

    This update has been posted now,  the 8.2.1.0 SDK drop is required to use it.

  • MattB-MSFT Profile Picture
    MattB-MSFT on at
    RE: Upgrading Visual Studio projects to use the new version of the CRM software developer toolkit

    We are adding back in Image support in a limited fashion in the new current toolkit to act as a stop gap for folks while we are making the larger changes that prompted us to remove it in the first place.

    The key missing item the original is code gen support in plugin classes, that will come back later along with several other updates in this area.

    The support for this has been added to the 8.2.0.3 SDK drop that is coming out in the next day or so, at which point we will post the updated toolkit that works with it.

    MattB

  • DirkRe Profile Picture
    DirkRe 15 on at
    RE: Upgrading Visual Studio projects to use the new version of the CRM software developer toolkit

    I had the same experience - a crmregister file created by my colleage with developer toolkit 2013 was wiped by my developer toolkit 365.

    I just receovered the change from GIT.

    Up to a fix of this problem I'll set the file to "Ignore on Commit" in the source control to avoid destroying the solution. See also community.dynamics.com/.../621031.

  • Suggested answer
    Ben Walker Profile Picture
    Ben Walker 265 on at
    RE: Upgrading Visual Studio projects to use the new version of the CRM software developer toolkit

    Answering my own question here - with the new version of the toolkit, you need to register images using the plugin registration tool - no way to do this in the toolkit at the moment and no point in adding anything in the crmregister file. I've flagged this on the connect site.

  • Ben Walker Profile Picture
    Ben Walker 265 on at
    RE: Upgrading Visual Studio projects to use the new version of the CRM software developer toolkit

    Thanks to all for the replies. Not against recreating the projects - as Tom says it is a good opportunity to review code, etc.

    Pawel - thanks for the recommendation - I've considered using Jason's alternative before, but wanted to see if the official toolkit was any better than previous - it does offer nice new things such as granular deployment, creation of early bound classes, switching profiling on, etc, and more to come, I understand.

    The main blocker at the moment for the new toolkit is that there is no option to register an image, and I've not worked out how to do this. Putting the image section into the crmregister file in the format it used to be in does not make any difference - images are not registered.

    Anyone worked out how to do this? Thanks.

  • ScottDurow Profile Picture
    ScottDurow 50,177 on at
    RE: Upgrading Visual Studio projects to use the new version of the CRM software developer toolkit

    Hi Ben,

    I have found the cleanest to be to re-create the project - although actually when you look at the two side by side they are very similar - the msbuild target is removed from the project file and there are some slightly different attributes in the crmregister file.

    Maybe you could write a tool for the community to migrate projects :)

    Cheers,

  • Suggested answer
    tw0sh3ds Profile Picture
    tw0sh3ds 5,600 on at
    RE: Upgrading Visual Studio projects to use the new version of the CRM software developer toolkit

    Hi Ben,

    Upgrade is always a good time to tidy things up. My advice - use this to remove Developer Toolkit, because it's a bad tool that leads to many problems. You just found one of it. It was not supported for so long that CRM Dev that were stuck with this could not even use Visual Studio 2015 (because last version of toolkit did not support VS 2015). I myself removed already Developer Toolkit from several projects because in the end it makes more trouble than help. Of course that's only my opinion, if you want to continue using this, you can but still you will have to rewrite the code to be compatible with the latest DT, why not spend that time to remove this tool?

    For managing plugins and WebResources much better solution are CRM Developer Extensions by Jason Lattimer

  • Suggested answer
    ThomasN Profile Picture
    ThomasN 3,190 on at
    RE: Upgrading Visual Studio projects to use the new version of the CRM software developer toolkit

    Hi Ben, thanks for reaching out.

    This is painful and not the response you want. I have not found another solution than recreating the projects. The issue is the code has changed so much that old 2011 versions usually use outdated methods, or could be improved with current methods or functions that now available in the SDK. In previous work we have always recreated, and took the time to optimize the work during an upgrade.

    Guido Preite has a great list of resources to check compatibility. This should speed up the process by identifying what code needs replaced and what code can just be copied over to new projects.

    www.crmanswers.net/.../resources-for-crm-developers.html

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

December Spotlight Star - Muhammad Affan

Congratulations to a top community star!

Top 10 leaders for November!

Congratulations to our November super stars!

Tips for Writing Effective Suggested Answers

Best practices for providing successful forum answers ✍️

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,269 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,198 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans