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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 22, 20262026-05-22T01:25:50+00:00 2026-05-22T01:25:50+00:00

This is somewhat specific and difficult situation to explain, so bear with me. I

  • 0

This is somewhat specific and difficult situation to explain, so bear with me.

I have created a UnityContainerExtension that is responsible for loading and configuring other .config files.

For example, my App.Config file looks like this:

  <configuration>

    <configSections>
        <section name="unity" type="Microsoft.Practices.Unity.Configuration.UnityConfigurationSection, Microsoft.Practices.Unity.Configuration, Version=2.0.414.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" />
    </configSections>

    <unity xmlns="http://schemas.microsoft.com/practices/2010/unity">

        <assembly name="SomeAssembly" />
        <namespace name="SomeAssembly.SomeNameSpace" />

        <container>

            <extension type="ConfigSectionExtension" />
            <extension type="TestExtension" />

        </container>

    </unity>

  </configuration>

My first extension ConfigSectionExtension runs code (following) that loads in and configures the container with another .config file. ex.

    var fileMap = new ExeConfigurationFileMap { ExeConfigFilename = "logging.config"};
    Configuration configuration = ConfigurationManager.OpenMappedExeConfiguration( fileMap, ConfigurationUserLevel.None );
    ((UnityConfigurationSection)configuration.GetSection( "unity" )).Configure( Container );  

This code runs fine, however the TestExtension extension in my config cannot be resolved after the Container has been configured with the logging.config file.

The specific response is

    "The type name or alias TestExtension could not be resolved."

If I remove the code that loads and configures the logging.config file with the container, then both extensions are found. Is there any way to make this work?

This is essentially my approach to the problem of not being able to link together multiple .config files. If someone knows a better way to link .config files together for Unity, I would of course be open to that solution as well.

  • 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-05-22T01:25:51+00:00Added an answer on May 22, 2026 at 1:25 am

    OK, I think I have an OK solution. For my extension I can just fully qualify the Type and it will work. ie.

        <extension type="MediaInjectorUI.ContainerExtensions.ConfigSectionExtension, MediaInjectorUI" />
        <extension type="MediaInjectorUI.ContainerExtensions.TestExtension, MediaInjectorUI" /> 
    

    Maybe not the prettiest thing in the world, but itdoes the job.

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

Sidebar

Related Questions

This is somewhat complicated to explain, so please bear with me. I have an
Is it possible to have nested set capabilities in this somewhat custom setup? Consider
This is somewhat of a follow-up to an answer here . I have a
This is somewhat of a follow-up question to this question . Suppose I have
I know that this is somewhat subjective, but I wonder if there is a
This question is relating to a specific functionality that a client has requested for
I understand that this question may seem somewhat ungrounded, but if someone knows anything
Okay, in my head this is somewhat complicated and I hope I can explain
EDIT: I've been convinced that this question is somewhat non-sensical. Thanks to those who
I'd like to have your opinion on a specific case, please. This is about

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.