“建立动作"和“复制到输出目录"

“建立动作

问题描述:

我不确定这是否是问这个问题的正确董事会.

好的,这是我的问题.我有2个项目,一个控制台应用程序和一个类库的解决方案,我的控制台应用程序引用了类库.在我的班级库中,我有一些Xml文件作为配置,我将构建操作设置为无".并复制到输出目录以总是复制".

当我编译解决方案时,我可以看到所有这些Xml文件都复制到类库的bin \ Debug或bin \ Release文件夹中,但没有被复制到控制台应用程序的bin文件夹.

除了运行post build event命令外,我是否可以将这些Xml文件自动复制到控制台应用程序文件夹?

感谢
Hardy

I am not sure if this this the correct board to ask this question.

OK, here is my question. I have a solution with 2 projects, a console application and a class library, my console app references to class library. In my class library I have some Xml files as config, I set build action to "none" and copy to output directory to "copy always".

When I compile the solution I can see all these Xml files are copied to class library's bin\Debug or bin\Release folder, BUT they are not copied to console app's bin folder.

Other than running post build event command, can I automatically copy these Xml files to my console app folder?

Thanks
Hardy

为什么不将类库的构建操作设置为编译"?

谢谢.
Why not set build action of class library to "compile"?

Thanks.