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 8186923
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 7, 20262026-06-07T02:23:19+00:00 2026-06-07T02:23:19+00:00

What is the best practice in the .NET world to manage transitive dependencies that

  • 0

What is the best practice in the .NET world to manage transitive dependencies that cause version conflict ?

In details :
Project A Depends on Project B which in turn depends on library C

also

Project A also depends on Project X which depends on a DIFFERENT and (potentially) incompatible version of library C.

A->B->Cv1.0
&
A->X->Cv2.0
where
Cv1.0 <> Cv2.0

  • Is there a way to make this work ?

  • Can it be done WITHOUT using the GAC ?

  • Can it be done even if B and X are in binary format only (source not accessible) ?

In other words is there a way where I can have Project B and X each using their own dependencies when used together in Project A without causing conflicts.

NOTE: I realize that ideally I should not have this problem at all but as reliance on external libraries expands this will be an unavoidable side effect. So I am wondering should it occur how best to deal with it.

  • 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-07T02:23:21+00:00Added an answer on June 7, 2026 at 2:23 am

    There are a lot of similar questions On Stack Overflow.
    For e.g. Referencing 2 different versions of log4net in the same solution

    Summary:

    1. Ensure that you deploy the assembly C in folders 1.0 and 2.0 respectively within the folder containing the main executable.
    2. Change app.config file and include something like following:
     <configuration>
       <runtime>
        <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
          <dependentAssembly>
           <assemblyIdentity name="C" publicKeyToken="C's public key token" />
            <codeBase version="version string for C1.0 e.g. 1.0.0.0" href="1.0\C.dll" />
            <codeBase version="version string for C2.0 e.g. 2.0.0.0" href="2.0\C.dll" />
           </assemblyIdentity>
          </dependentAssembly>
        </assemblyBinding>
       </runtime>
     </configuration>
    

    you can get the public key token of C using sn -T C.dll

    If v1.0 and v2.0 of C have different public key (though ideally they shouldn’t) then include two dependentAssembly tags.

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

Sidebar

Related Questions

What would be best practice to localize your ASP.NET MVC application? I would like
What's the best practice for using ASP.NET expressions inside an external Javascript file? I'm
What is the best practice for submitting forms in ASP.NET MVC? I have been
Whats the best practice for implementing a confirmation page in .Net? I've used response.redirect(Thankyou.aspx)
I'm just looking for best practice reassurance on working with jQuery and ASP.Net, before
We're building a simple ADO.Net infrastructure, and looking for the best practice for creating
What are the 'best' practices regarding circular dependencies amongst DLL's in .net? I am
My question is around the best practice for dividing up an asp.net mvc web
This is more or less a best-practice question: I'm working on a site that
In my pre-ASP.NET development environment, there was a near-universal best practice: * NEVER use

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.