assemblies

.NET Assembly Dependencies

冷暖自知 提交于 2020-01-01 05:27:20
问题 Perhaps I am missing something obvious here but... I have built a reusable generic C# class library project say (A.dll) which references 3 other assemblies say (B.dll, C.dll and D.dll) However if I want to reuse my component A.dll in another project I still have to include the references to B.dll, C.dll and D.dll. Is there any way you can configure A.dll to build all its dependencies into the A.dll so I don't have to include the other 3 assemblies? Cheers 回答1: It's possible to merge

How can I get all the inherited classes of a base class? [duplicate]

↘锁芯ラ 提交于 2020-01-01 04:30:06
问题 This question already has answers here : How to find all the types in an Assembly that Inherit from a Specific Type C# (4 answers) Get all derived types of a type (8 answers) Closed 6 years ago . class Foo { } class Foo1 : Foo { } class Foo2 : Foo { } How would I be able to get all the classes that use Foo as a base class? The inherited classes aren't necessary in the same assembly. 回答1: This is not fast, but as long as Foo is a concrete type (not an interface), then it should work. Foo

Tool to show assembly dependencies

安稳与你 提交于 2019-12-31 14:32:03
问题 I begun work in a new project with lots of assemblies in a single solution. I am not familiar yet with the assembly dependencies and having a hard time figuring out which assembly depends on another. Do you know any tools that are capable to show a dependency list or better a visual graph of it? Any help appreciated ! 回答1: NDepend is the king when it comes to dependency graph analysis. The tool proposes: a dependency graph a dependency matrix, and also some C# LINQ queries can be edited (or

Reflection - Iterate object's properties recursively within my own assemblies (Vb.Net/3.5)

喜你入骨 提交于 2019-12-31 05:23:06
问题 I wonder if anyone can help me - I've not done much with reflection but understand the basic principles. What I'm trying to do: I'm in the process of developing a class that gathers a lot of information about the local system, network, etc... to be used for automated bug reporting. Instead of having to change my test harness every time I add a new property, I'd (ideally) like to be able to serialise the lot as an XML string and just display that in a textbox. Unfortunately, the Framework won

C#: How to embed DLL into resourcefile (no dll copy in program directory)

余生长醉 提交于 2019-12-31 05:12:12
问题 I have a C# application (project A) that requires X.dll. I have added the project that produces X.dll to A as a reference in visual studio. I have also added the release build of X.dll to a resource file in A as a binary. I have told project A not to copy X.dll to the output directory. Now I want A.exe to load, say "hey I can't find this file", then look in the resource file and use Assembly.Load(byte[]) get X.dll back. I have the code that re-magicifies the DLL back, however this code never

ASP.NET Website's BIN directory and references

不打扰是莪最后的温柔 提交于 2019-12-31 02:23:20
问题 Imagine the following solution: Website ABC.com (not Web Application) BLL (business logic layer in a seperate assembly) DTO (dto objects in their own assembly) DAL (data access layer in it's own assembly as well). The BLL has a reference to the DAL. The BLL has a reference to the DTO layer. The Website project references the BLL. When one compiles the website project, the following DLLs will appear in the BIN directory: BLL.dll DTO.dll DAL.dll When one goes to preview the site, an error

WinSxS: How to take dependency on specific version of gdiplus.dll?

北慕城南 提交于 2019-12-31 01:49:10
问题 I need to add a dependency on a specific version of GDIPlus. This is the version of GDI+ that i want: I want to be sure that I'm using this version for a specific compatibility reason. I've added an assembly manifest to my executable, defining my dependancy on the version of GdiPlus : <dependency> <dependentAssembly> <assemblyIdentity type="win32" name="Microsoft.Windows.GdiPlus" pubicKeyToken="6595b64144ccf1df" version="5.1.3102.2180" processorArchitecture="x86" language="*" /> <

Why do I get System.IO.FileLoadException: Could not load file or assembly, about once a week on my ASP.Net Website?

孤街醉人 提交于 2019-12-30 06:46:34
问题 I have a rather simple internal ASP.Net Website that has issues loading the Microsoft.Practices.EnterpriseLibrary.Data dll about once a week. Here is the Exception message: System.IO.FileLoadException: Could not load file or assembly 'Microsoft.Practices.EnterpriseLibrary.Data, Version=2.0.0.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies. Access is denied. File name: 'Microsoft.Practices.EnterpriseLibrary.Data, Version=2.0.0.0, Culture=neutral, PublicKeyToken=null' at

Why do I get System.IO.FileLoadException: Could not load file or assembly, about once a week on my ASP.Net Website?

∥☆過路亽.° 提交于 2019-12-30 06:46:10
问题 I have a rather simple internal ASP.Net Website that has issues loading the Microsoft.Practices.EnterpriseLibrary.Data dll about once a week. Here is the Exception message: System.IO.FileLoadException: Could not load file or assembly 'Microsoft.Practices.EnterpriseLibrary.Data, Version=2.0.0.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies. Access is denied. File name: 'Microsoft.Practices.EnterpriseLibrary.Data, Version=2.0.0.0, Culture=neutral, PublicKeyToken=null' at

VS.NET: Project Refs vs. Assembly Refs

流过昼夜 提交于 2019-12-30 06:11:26
问题 There's some debate here over which is better for referencing our common code base from other projects: by project or by assembly. I'm in favor of referencing the project, especially since we have automated unit tests that prove that the common code does what it needs to. The thought from the other camp is to lock down those projects and only release assemblies once a month or something. Then force all projects to reference the assemblies. They think this will protect them from deploying