web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Microsoft Dynamics CRM (Archived)

Error building and deploying plugins with CRM 2013 Developer toolkit to CRM Online

(0) ShareShare
ReportReport
Posted on by

For development purposes on CRM Online and more important the ability to debug I want to work with the CRM development toolkit.  I experience some problems and I hope anyone can give me some guidance?

 

Specs

- Working with Visual Studio Community (VS 2013)

- Developer toolkit CRM 2013 (because 2015 is not yet available as far as I am aware)

- CRM 2015 Online (read that it should also work with the CRM 2013 developer toolkit)

 

By changing VS studio install and regedit (see link under) I managed to connect to CRM and create plugins:

http://www.hashtagcrm.com/?p=79

 

When building my project I was unable to build, because the targeted framework was different. After I have changed the .NET framework of the project/solutions to 4.5.2. I was able to build the project in Visual Studio, but I receive the following warnings refering to the primary reference:

-----------------------------------------------------------------------------------

1>------ Build started: Project: CrmPackage, Configuration: Debug Any CPU ------

1>C:\Program Files (x86)\MSBuild\12.0\bin\Microsoft.Common.CurrentVersion.targets(1697,5): warning MSB3274: The primary reference "C:\Users\nico.van.de.heiden\Documents\Visual Studio 2013\Projects\Connector\Connector\Plugins\bin\Debug\Connector.Plugins.dll" could not be resolved because it was built against the ".NETFramework,Version=v4.5.2" framework. This is a higher version than the currently targeted framework ".NETFramework,Version=v4.5".

1>C:\Program Files (x86)\MSBuild\12.0\bin\Microsoft.Common.CurrentVersion.targets(1697,5): warning MSB3274: The primary reference "C:\Users\nico.van.de.heiden\Documents\Visual Studio 2013\Projects\Connector\Connector\Workflow\bin\Debug\Connector.Workflow.dll" could not be resolved because it was built against the ".NETFramework,Version=v4.5.2" framework. This is a higher version than the currently targeted framework ".NETFramework,Version=v4.5".

1>C:\Program Files (x86)\MSBuild\12.0\bin\Microsoft.Common.CurrentVersion.targets(1697,5): warning MSB3275: The primary reference "C:\Users\nico.van.de.heiden\Documents\Visual Studio 2013\Projects\Connector\Connector\Plugins\bin\Debug\Connector.Plugins.dll" could not be resolved because it has an indirect dependency on the assembly "Microsoft.Xrm.Sdk, Version=7.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" which was built against the ".NETFramework,Version=v4.5.2" framework. This is a higher version than the currently targeted framework ".NETFramework,Version=v4.5".

========== Build: 1 succeeded, 0 failed, 2 up-to-date, 0 skipped ==========

------------------------------------------------------------------------------------------------

But the project builded, so it tried to deploy my project. When I deployed to CRM I got the following error:

Error registering plugins and/or workflows. Assembly bin\Debug\DPMConnector.Plugins.dll could not be found.         

C:\Program Files (x86)\MSBuild\Microsoft\CRM\Microsoft.CrmDeveloperTools.12.targets        

176 CrmPackage

Hopefully someone can help me out here, because I do like the developer toolkit and prefer to work this way.

*This post is locked for comments

I have the same question (0)
  • Suggested answer
    Mithilesh Kumar Profile Picture
    10,047 on at

    Hi,

    If you want to use the Developer's Toolkit, you will have to use Visual Studio 2012. Developers Toolkit is not supported for Visual Studio 2013.

    Hope that helps

    Thanks

  • Verified answer
    Royal King Profile Picture
    27,686 on at

    CRM 2013 does not support .net framework 4.5 or 4.5.2 . Build the dll using .net framework 4.0 that should work in crm 2013 as well as 2015 .

    Support for .NET Framework Versions

    The following describes the support considerations for custom code written with Microsoft Visual Studio 2010, 2012, or 2013, and the Microsoft .NET Framework 4. The Microsoft .NET Framework 4.5 is currently not supported for building managed code applications, plug-ins, and custom workflow activities that link to the SDK assemblies.

    Any web service client created by using Visual Studio and the Microsoft .NET Framework 4 that calls the Microsoft Dynamics CRM web services is fully supported in Microsoft Dynamics CRM. The use of ASP.NET AJAX is supported.

    Any .NET assembly that is created with Visual Studio and the Microsoft .NET Framework 4 for use in Microsoft Dynamics CRM as a Microsoft Dynamics CRM plug-in assembly or as a Microsoft Dynamics CRM custom workflow activity is supported.

    Any visualization (chart) that is created with .NET Framework 4 or 3.5 is supported.

    Here is the link to microsoft document for supported .net framework

    msdn.microsoft.com/.../gg328350(v=crm.6).aspx

  • Suggested answer
    ScottDurow Profile Picture
    21 on at

    Hi,

    This can be resolved by editing the CRM Deployment project and editing the target framework reference in the project file. Set it to 4.5.2 and it should build and deploy fine.

    Thanks,

    Scott

  • Community Member Profile Picture
    on at

    Hi Scot,

    Thanks for you reply.

    My solution exists out of the projects CrmPackage, Plugins and Workflow. In both the Plugins as Workflow I already changed the Target framework to .NET 4.5.2 in the application properties. This indeed enabled me to build the project(s), but with the warnings.

    Are you referring to another property / location where I have to change the Target .NET framework?

    Thanks,

    Nico

  • Community Member Profile Picture
    on at

    Hi Chitra,

    Thanks for your response. Based on your post I rebuilded my code to .NET framework 4.0 end I was able to deploy my code.

    Do you have any idea when 4.5 will be supported and do you see any downside that it will not yet work with 4.5 and higher?

    Thanks,

    Nico

  • Suggested answer
    ScottDurow Profile Picture
    21 on at

    Hi,

    Yes - you need to open the CrmPackage project into notepad and change the line:

    <TargetFrameworkVersion>v4.5</TargetFrameworkVersion>

    to

    <TargetFrameworkVersion>v4.5.2</TargetFrameworkVersion>

    I've been using the Developer toolkit targeted against 4.5.2 and deploying to CRM2015 with no problems after doing this.

    Hope this helps,

    Scott

  • Suggested answer
    Mithilesh Kumar Profile Picture
    10,047 on at

    Hi,

    You can use Visual Studio 2013 to develop your Solution Targeted at 4.5.2.

    Download the Microsoft .Net Framework 4.5.2 Developer Pack and install it

    http://www.microsoft.com/en-my/download/details.aspx?id=42637

    Follow the article below

    http://zsoltzombik.com/2015/03/05/missing-net-framework-4-5-2-in-visual-studio-2013/

    Hope that helps

    Thanks

  • Community Member Profile Picture
    on at

    Thanks Scott.

  • Community Member Profile Picture
    on at

    the solution worked for me, thanks Scott!

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

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > 🔒一 Microsoft Dynamics CRM (Archived)

#1
SA-08121319-0 Profile Picture

SA-08121319-0 4

#1
Calum MacFarlane Profile Picture

Calum MacFarlane 4

#3
Alex Fun Wei Jie Profile Picture

Alex Fun Wei Jie 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans