Suzanne Cook's .NET CLR Notes

Common Language Runtime Developer

May, 2003

  • Suzanne Cook's .NET CLR Notes

    Debugging Assembly Loading Failures

    • 108 Comments
    So...you're seeing a FileNotFoundException, FileLoadException, BadImageFormatException or you suspect an assembly loading failure? Try the steps below to start your debugging process. First, get the Message property from the exception. If the exception...
  • Suzanne Cook's .NET CLR Notes

    Choosing a Binding Context

    • 41 Comments
    There are three 'contexts' for assembly binding: Load context In general, if the assembly was found by probing in the GAC, a host assembly store (if hosted), or the ApplicationBase / PrivateBinPaths of the AppDomain, the assembly will be loaded...
  • Suzanne Cook's .NET CLR Notes

    Assembly Display Names

    • 32 Comments
    An assembly display name should include the assembly simple name, version, culture and public key token. The assembly simple name is usually the file name of the assembly without the extension (“.dll” or “.exe”). For example, the assembly display name...
  • Suzanne Cook's .NET CLR Notes

    When to Change File/Assembly Versions

    • 28 Comments
    First of all, file versions and assembly versions need not coincide with each other. I recommend that file versions change with each build. But, don’t change assembly versions with each build just so that you can tell the difference between two versions...
  • Suzanne Cook's .NET CLR Notes

    Avoid Partial Binds

    • 13 Comments
    A partial bind is when only part of the assembly display name is given when loading an assembly. Assembly.LoadWithPartialName() also uses partial binding. First, it calls Assembly.Load(). But, if that fails to find the assembly, it will return the...
  • Suzanne Cook's .NET CLR Notes

    Using Type.GetType(typeName)

    • 5 Comments
    If no assembly is specified, Type.GetType() will only look in the calling assembly and then mscorlib.dll for the type. For it to look in any other assembly, you need to give the Type.AssemblyQualifiedName for the type. For example: Type.GetType("System...
Page 1 of 1 (6 items)