Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7781151
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 1, 20262026-06-01T19:08:07+00:00 2026-06-01T19:08:07+00:00

I’ve got a situation where an application uses a plugin model to load assemblies

  • 0

I’ve got a situation where an application uses a plugin model to load assemblies at runtime. Most of these assemblies have a further dependency on a common assembly which is modified over time.

For example, Plugin A depends on Version 1 of Common and Plugin B depends on Version 2 of Common.

The plugins are self contained and the common assemblies are strongly named, so in a purely managed environment the different Common assemblies get loaded and there’s no danger of an accidental cast between types from the different Common versions and everything works fine.

When loading from a mixed-mode assembly, which is a requirement, we are in a situation where the first loaded assembly ‘wins’. So in the example, Plugin B would attempt to load against Common v1 that in our case throws a TypeLoadException because of some missing types in the old version of the assembly.

How can we force the C++/CLI environment to honor the verisoning of the reference in the plugins?

We’ve tried:

  1. /FU compiler option against the appropriate versions

  2. #using against the appropriate versions

  3. Specific Version reference in the .NET reference dialog using the strongly-named components.

None of these have been effective in getting the V2 assembly to be referenced.

Update: Here’s a bit more detail about the system, it is sensitive so I’ll stick with the A/B language above.

CommonAssembly.dll v1 and v2 (C#) strong-named

PluginA: C++/CLI compiled with /clr, CommonAssembly v1 referenced with /FU compiler option

PluginB: C++/CLI compiled with /clr, CommonAssembly v2 referenced with /FU compiler option

Main Application: Unmanaged — loads PluginA and PluginB at runtime with no direct references.

The unmanaged application loads PluginA, which loads CommonAssembly v1. The application then tries to load PluginB which requires CommonAssembly v2. The CLR tries to use the v1 instead and there is a TypeLoadException.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-01T19:08:08+00:00Added an answer on June 1, 2026 at 7:08 pm

    The mixed-mode assembly includes a native portion, and you can’t load more than one copy of this native portion into a single process.

    Mixed-mode assemblies also don’t play well with AppDomains, because the native portion is process-wide.

    You may have some luck with renaming one of the versions, since that’s how Windows tracks native DLLs.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a string like this: La Torre Eiffel paragonata all’Everest What PHP function
I have just tried to save a simple *.rtf file with some websites and
link Im having trouble converting the html entites into html characters, (&# 8217;) i
I have a jquery bug and I've been looking for hours now, I can't
I've got a string that has curly quotes in it. I'd like to replace
this is what i have right now Drawing an RSS feed into the php,
I have this code to decode numeric html entities to the UTF8 equivalent character.
I have a French site that I want to parse, but am running into
I'm parsing an RSS feed that has an ’ in it. SimpleXML turns this
I have this code: - (void)parser:(NSXMLParser *)parser foundCDATA:(NSData *)CDATABlock { NSString *someString = [[NSString

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.