Visual Studio 编译后将 .dll 和 .pdb 添加到项目中 [英] Visual Studio adds .dll and .pdb to project after compiling

查看:39
本文介绍了Visual Studio 编译后将 .dll 和 .pdb 添加到项目中的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在我的 Visual Studio 2008 web vbproj 中,我只在 bin 文件夹中包含了某些文件.我正在使用 browserhawk,它需要一些浏览器定义文件(maindefs.bdd 等...).我现在在部署网络应用程序时总是拥有它们.

In my Visual Studio 2008 web vbproj, I have included only certain files in the bin folder. I am using browserhawk and it needs to have some browser definition files (maindefs.bdd, etc...). I now always have them when I deploy the web app.

当我编译我的应用程序时,VS 会自动将新编译的 .dll 添加到项目中.我曾尝试对添加的文件使用从项目中排除",但在我清理解决方案后,它再次重新添加它们.

When I compile my application, VS automatically adds the newly compiled .dlls to the project. I have tried to use "Exclude from Project" on the files that were added, but after I clean the solution, it re-adds them again.

如何禁用此操作?

推荐答案

如果您的 bin 文件夹包含在您的项目中,您将无法这样做.相反,您可以将浏览器定义文件放在项目中的单独文件夹下,或仅在项目下,并将构建操作更改为内容(或无)并将复制到输出目录更改为始终复制(或如果较新则复制)您要转到 bin 文件夹的每个文件的属性.这样文件就会成为项目的一部分并自动添加到 bin 文件夹中.

You won't be able to if your bin folder is included in your project. Instead, you can put your browser definition files in your project under a separate folder, or just under the project, and change the Build Action to Content (or None) and Copy to Output Directory to Copy Always (or Copy if Newer) in the properties for each file you want to go to your bin folder. That way the files are part of the project and get added to the bin folder automatically.

这篇关于Visual Studio 编译后将 .dll 和 .pdb 添加到项目中的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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