I have the following class located in Assembly A. The assembly has a reference to StructureMap 2.6.1.
public static class Bootstrapper
{
public static void Bootstrap(string databaseName)
{
StructureMapBootstrapper.Bootstrap(databaseName);
}
}
I'm referencing Assembly A in a completely different Assembly (B) and I"m getting the following runtime error when this line is called:
Bootstrapper.Bootstrap(db);
The runtime error is:
FileNotFoundException: Could not load file or assembly 'StructureMap, Version=2.6.1.0, Culture=neutral, PublicKeyToken=e60ad81abae3c223' or one of its dependencies. The system cannot find the file specified.
I'm constantly having to copy StructureMap.dll to the bin directory of Assembly B. This is incredibly annoying. Any suggestions on how to resolve this? Does anybody know the general rules regarding when assemblies referenced by AssemblyA will be needed by AssemblyB?
Thanks!