I have created several DLL (.NET) libraries that are used in several projects. In these DLL libraries I want to know/retrieve which assembly (EXE) calls/uses the library, so if possible I want to know info like assembly name (EXE), strong name, version number, etc.
NB: Examples may be in C# or VB. I use both languages.
You can use System.Reflection => Assembly.GetCallingAssembly() should do the job. http://msdn.microsoft.com/en-en/library/system.reflection.assembly.getcallingassembly.aspx
You can use reflection for this task.
http://msdn.microsoft.com/en-us/magazine/cc163750.aspx
http://www.intertech.com/Blog/Post/The-Role-of-Reflection-in-VB-(NET).aspx
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.