Here's a recursive one that does circular reference checking, as well.
/
private static void GetReferences(Assembly asm, DictionaryList> referencesList)
{
List refs = null;
if (!referencesList.ContainsKey(asm.FullName))
{
refs = new List()
> Try this:
>
> List asmNames = new List();
> // If called by a method defined in a class in FooBar
> foreach (Assembly asm in
> System.Reflection.Assembly.GetCallingAssembly().GetReferencedAssemblies(
> ))
>asmNames.Add(asm.FullName);
That won't work for 100%.
UI.exe calls BL
Try this:
List asmNames = new List();
// If called by a method defined in a class in FooBar
foreach (Assembly asm in
System.Reflection.Assembly.GetCallingAssembly().GetReferencedAssemblies(
))
asmNames.Add(asm.FullName);
// Kristofer
-Original Message-
From: Discussion of advanced .N