You can restore startup of MDriven Designer or MDriven Framework for VS2022 when an older Visual Studio 2019/17 installation has left incompatible assemblies in the Windows Global Assembly Cache (GAC).
Symptoms
Use this procedure when MDriven Designer or MDriven Framework for VS2022 fails while loading the model designer or plug-ins, and the exception refers to an assembly-version mismatch. Typical messages include:
Problem loading plugins. Exception in 'Modlr.Logic.ModlrLogic'
or:
Could not load file or assembly 'GenericFindInWindowControl, Version=7.0.0.13804, Culture=neutral,
PublicKeyToken=46a833be9e90de8c' or one of its dependencies.
The located assembly's manifest definition does not match the assembly reference.
(Exception from HRESULT: 0x80131040)
The type initializer for 'Modlr.Logic.ModlrLogic' threw an exception.
Cause
The Global Assembly Cache (GAC) is a Windows assembly store. Older versions of MDriven Framework for Visual Studio 2019/17 placed assemblies in the GAC. MDriven Designer and MDriven Framework for VS2022 do not use the GAC, but stale assemblies from the older installation can still be resolved during startup and conflict with the assemblies required by the newer software.
The conflict commonly involves GenericFindInWindowControl, WECPOFLogic, or assemblies whose folder name starts with Eco..
Fix the stale GAC assemblies
Choose one of the following approaches. Both address the same stale-assembly issue.
Option 1: Refresh the older Visual Studio 2019/17 framework installation
- Install the latest available version of MDriven Framework for VS2019/17.
- Start MDriven Designer or MDriven Framework for VS2022 again.
Installing the updated VS2019/17 framework refreshes the affected GAC assemblies with versions that work with the newer MDriven tools.
Option 2: Remove the named stale assembly folders from the GAC
- Open Windows File Explorer.
- Go to
C:\Windows\Microsoft.NET\assembly\GAC_MSIL\. - Delete only the following folders and their contents:
GenericFindInWindowControlWECPOFLogic- Every folder whose name matches
Eco.*
- Start MDriven Designer or MDriven Framework for VS2022 again.
Do not remove unrelated folders from GAC_MSIL. This procedure targets the old assemblies known to cause the MDriven startup conflict.
Verify the result
After either fix, start the affected application and open the model designer. The plug-in loading error and the Modlr.Logic.ModlrLogic type-initializer exception should no longer occur.
If the error is different
This page covers a specific GAC version conflict during MDriven Designer or MDriven Framework startup. Do not use it as a general fix for all startup exceptions.
- If you receive No suitable constructor found, check for conflicting
Eco.InterfacesandEco.*assemblies in the GAC or CodeDress assembly locations. See HowTos:Fix 'No suitable constructor found' Error. - If a deployed Turnkey application does not start under IIS, use HowTos:Troubleshooting IIS application startup issues.
- If an MDrivenServer server-side action fails after the server has started, capture its error details and inspect server activity as described in Documentation:Debugging MDrivenServer Serverside actions.
- If a server-side exception is caused by text that exceeds an attribute's database length, see Documentation:String attribute overflowing.
