Problem
I have a solution that contains 10+ projects. The most important being:
- SharePoint 2013
- WCF Service
- Windows Service
- Various test, Python, and Powershell related projects
I noticed that the projects contained a large number of models/classes that were repeated throughout all of the projects. To cut down on repeat code, I created a new project to house shared code. Unfortunately, I now receive this error at run-time:
"Method not found: [Name of method you tried to call]"
for any method in the shared project. It is worth noting that I have:
- Added a reference to the new project for all project's that use it
- This error ONLY occurs at RUNTIME
I am able to get the SharePoint solution to work if I add the shared project as an 'Additional Assembly' in the 'Package.Package' configuration file. However, this adds the shared project to the Global Assembly Cache (GAC), and still suffers from issues each time the shared project is updated.
Question
How can I deploy individual projects that reference code in the shared project without them blowing up at RunTime?
RELATED:
- WCF Method not found after signing an assembly
- My shared assembly is signed (required to work with SharePoint)
- Fault Exception - Method not found
- Trying to deploy a GAC install; Prefer to deploy in BIN folder
- https://stackoverflow.com/questions/7578538/method-not-found-on-runtime
- Drag and drop a DLL to the GAC ("assembly") in windows server 2008 .net 4.0