c# - Dll usage by .NET application -


have question .net experts.

i have set of winforms applications uses subset of dll's (some of them shared between apps). binaries resides in same directory. need split winforms apps , take dll's needed concrete app. how can (need fast "5-min" solution)?

options considered:

  1. domain.executeassembly(@"exefilename"); domain.getassemblies(); //to determine assemblies used app.

    needs single thread apartment attribute or separate thread. has issues x86, x64 , anycpu builds. lot of tricks security, framework versions , on.

    so, think not "5 min" solution , needs additional investigation.

  2. assembly.getreferencedassemblies()

    has 1 level limitation (doesn't work when assembly references assembly in turn references assembly). not work raw assembly loading (when read file , load appdomain.load method (byte[], byte[]))

  3. process.modules (from system.diagnostics)

    doesn't work starting .net 4 (it bug on msft connect entered issue). great "5min" solution .net 3.5, need solution .net 4.5.

  4. just execute app , delete every dll in folder. used not deleted (file locked out). still, doesn't work raw assembly loading.

do have other ideas?

if remember correctly, ildasm.exe recursively checks dll dependencies you.


Comments

Popular posts from this blog

blackberry 10 - how to add multiple markers on the google map just by url? -

php - guestbook returning database data to flash -

delphi - Dynamic file type icon -