简体   繁体   中英

WPF C# image and file inegration into application

嗨,我正在开发一个 WPF c# 项目,并希望附加一个文本文件和集成到其中的图像文件,以便如果我将可执行文件导出到任何其他 PC,它将轻松运行...

you are thinking about this in the wrong way, Visual Studio doesn't manage installation on Client machines it only handles building the code for you to run, the thing that manages the installation is the installer

if you want to use a publish installer like click once then you can use Visual Studio to set the publication rules (see https://msdn.microsoft.com/en-us/library/142dbbz4%28v=vs.90%29.aspx ), otherwise you actually need to create an installer (see https://msdn.microsoft.com/en-us/library/gg513936.aspx )

EDIT: If i'm misunderstanding your question which i took as how do you get your resourced files to be on the client machine with the exe file, if your question is how to Embed thee resource in the first place then How to refer to Embedded Resources from XAML? provides a very good answer

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM