Visual Studio生成选项-mscorlib.dll [英] Visual Studio build options - mscorlib.dll

查看:121
本文介绍了Visual Studio生成选项-mscorlib.dll的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好,

任何人都可以指导我在使用时使用不引用mscorlib.dll"检查选项来运行该应用程序. ..

Hi All,

Could anybody guide me to run the application with "Do not reference mscorlib.dll" check option when to use. is it helpful in making C# COM DLLs ?..

推荐答案

否,它对与COM相关的任何内容都没有帮助(顺便说一句,为什么要完全使用COM? !).

创建一些程序集几乎可以完全用作库是很有用的.您实际上可以将其用作应用程序,但是返回我现在可以看到的任何内容的唯一方法是退出代码. (这是因为您不能使用任何东西,甚至不能使用文件(!),甚至不能使用控制台!)

这样的程序集可以不受任何.NET库的依赖.这将使您的资料库具有高度的可移植性.

如果在Visual Studio下转到常规项目的引用,则可以看到该库中的内容,单击引用"System"(不是"System.Core",这是多余的),您将看到所有内容.被剥夺了.实际上,没有Math库,您将只能执行计算.不过,您可以引用其他一些程序集.

—SA
No, it is not helpful for anything related to COM (by the way, why using COM at all?!).

It can be useful to create some assembly which can be used almost exclusively as a library. You can actually use it as application, but the only way to return anything I can see right now would be the exit code. (This is because you cannot use anything, not even files (!) and not even the console!)

Such assembly can be free from dependencies on any .NET libraries. It would make your library highly portable.

You can see what is in this library if you go to a regular project''s references under Visual Studio, click at the reference "System" (not "System.Core", it is the extra) — you will see all you''re deprived of. Practically, you will be able to do only calculations, without Math library. You could reference some other assemblies though.

—SA


我认为,这是构建应用程序所必需的.

不要引用mscorlib.dll-(WRT-MSDN注意).

指定是否将mscorlib.dll导入到您的程序中,从而定义整个System命名空间.如果要定义或创建自己的系统名称空间和对象,请选中此框.有关更多信息,请参见/nostdlib(不导入标准库)(C#编译器选项).

我认为,不应在构建选项中选择绕过mscorlib.dll.何时使用此选项,请说明理由.
I think, this is must to build application.

Do not reference mscorlib.dll - (wrt - MSDN Note).

Specifies whether mscorlib.dll will be imported into your program, defining the entire System namespace. Check this box if you want to define or create your own System namespace and objects. For more information, see /nostdlib (Do Not Import Standard Library) (C# Compiler Options).

I think, should not select to bypass mscorlib.dll in the build options. When to use this option please justify.


这篇关于Visual Studio生成选项-mscorlib.dll的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆