I have the following inside my Dev machine:-
but when i click on start debugging the got this weird exception :-
Severity Code Description Project File Line Suppression State Error Unable to load one or more of the requested types. Retrieve the LoaderExceptions property for more information. SharePointProject6
here is how my SP 2016 solution looks like:-
also my project is showing this warning:-
Severity Code Description Project File Line Suppression State Warning Unhandled exception occurred while calling method 'projectService_ProjectInitialized' of type 'Microsoft.VisualStudio.SharePoint.WorkflowDesignerSupport.PackageBootstrapper, Microsoft.VisualStudio.SharePoint.WorkflowDesignerSupport, Version=14.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a'. Exception: System.IO.FileNotFoundException. Message: Could not load file or assembly 'Microsoft.Activities.Design.Services, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The system cannot find the file specified. SharePointProject6 0
so can anyone advice on this please? Thanks
EDIT
here is the references
:-
EDIT-2
when i checked my current references from the following location "C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.5
", i got the following:-
EDIT-3
now i went to another machine which have visual studio 2015 installed (actually it is my dev laptop), and i copies the Microsoft.Activities.Design.Services.dll
from C:\Windows\Microsoft.NET\assembly\GAC_MSIL\Microsoft.Activities.Design.Services\v4.0_1.0.0.0__31bf3856ad364e35
, then i paste it inside my server which have sharepoint and visual studio installed:-
then i open the visual studio project, i browse for the Microsoft.Activities.Design.Services.dll
, and i add it inside my visual studio project, as follow:-
but i am still facing the same error. now i try running the visual studio as Admin.Plus i clear the bin folder of my project. Plus i repair the visual studio and i repair the development tools for visual studio... but when i run the project I will receive the same error...
Edit-4 now i have repair Visual Studio 2015, and i got these messages:-
so i am not sure if these messages can be related to the problem i am facing ?
Microsoft.VisualStudio.SharePoint.WorkflowDesignerSupport
and thus Microsoft.Activities.Design.Services.dll
are loaded by Visual Studio (devenv.exe
) itself, not by the component you're writing, so VS won't look for it in your project directories.
You could probably work around the problem by copying Microsoft.Activities.Design.Services.dll
into the same directory as Microsoft.VisualStudio.SharePoint.WorkflowDesignerSupport
, C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE\Extensions\Microsoft\SharePoint\Extensions\WFDesignerSupport\
.
The best way to do it is certainly to install the missing Workflow Manager
component of which this DLL is a part. It can be downloaded from Microsoft as described here : https://msdn.microsoft.com/en-us/library/jj193448(v=azure.10).aspx
Edit
According to https://msdn.microsoft.com/en-us/library/yx7xezcf(v=vs.110).aspx, an executable can specify in it's config file where to look for assemblies, which VS does. devenv.exe.config
contains :
<probing privatePath="PublicAssemblies;PrivateAssemblies;...
so it should look for the dlls in C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE\PrivateAssemblies
.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With