[英]what is a recommended way to create a dependency for a windows forms application?
I want to associate a text or xml file with my project. 我想将文本或xml文件与我的项目相关联。 So when the applications gets published this text file should tag along.
因此,当应用程序发布时,该文本文件应随之标记。 How do you do this in visual studio?
您如何在Visual Studio中做到这一点?
Normally I'd just add the file to the project, set the Build Action
to Content
and Copy to Output directory
to Always Copy
. 通常,我只是将文件添加到项目中,将“
Build Action
设置为Build Action
Content
, Copy to Output directory
为“ Always Copy
。 I don't normally publish projects though (I just copy the files) but I'd assume this would still be the correct way. 我通常不发布项目(我只是复制文件),但是我认为这仍然是正确的方法。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.