Unity application block 2.0 - The given assembly name or codebase was invalid

前端 未结 7 1546
-上瘾入骨i
-上瘾入骨i 2021-01-04 03:26

Interfaces (In the assembly named \"Interfaces\". In project :- Interfaces)

namespace Interfaces
{
    public interface IDoSomeWork1
    {
          


        
7条回答
  •  孤街浪徒
    2021-01-04 04:07

    I found that the least time consuming method of finding which Type exactly failed to bind is the following:

    1. Go to Sources section of Unity page at codeplex http://unity.codeplex.com/SourceControl/list/changesets
    2. Select a version and download the sources
    3. Build DEBUG version of Unity and Unity.Configuration (if your project uses more of unity assemblies, build them as well)
    4. Remove references to unity from your project and add references to assemblies from step 3
    5. In Visual Studio go to Debug > Exceptions and make sure Common Language Runtime Exceptions has a checkbox in the Thrown column.

    Now go crash that thing. Execution will stop in Unitys' TypeResolverImpl.SearchAssemblies method and typeNameOrAlias parameter will hold the answer!

提交回复
热议问题