Managed Satellite DLLs for Extensibility

As you may know, some extensibility (both Add-in and VSIP Packages) features now support storing resources in managed Satellite DLLs. But we have had a few comments that people have not been able to get this to work. In all cases it turned out that the Satellite DLL could not be loaded, either because the DLL was not in the correct location, or because the DLL was not properly created (problems with version numbers, etc). The following code is very similar to the code we use inside of VS to locate a Satellite DLL. Simply create a C# console app, past in the following code, change the pathToAssembly to point to either the Add-in or Package DLL, change lcid to your locale (1033 is en-US), and it will tell you if your Satellite DLL can be found or not.

static void Main(string[] args)
{

try
{
string pathToAssembly = @"...";
int lcid = 1033;
System.Reflection.Assembly asm = System.Reflection.Assembly.LoadFrom(pathToAssembly);
System.Globalization.CultureInfo culture = new System.Globalization.CultureInfo(lcid);
System.Reflection.Assembly assemblyForResources = asm.GetSatelliteAssembly(culture);
}
catch (System.IO.FileNotFoundException fnf)
{
Console.WriteLine("File not found: " + fnf.FileName);
return;
}
Console.WriteLine("Satellite DLL found.");
}