clickonce file missing

拟墨画扇 提交于 2019-12-11 07:43:22

问题


Using Clickonce with VS 2010 and .NET framework Client profile 3.5, I have several file folders with application level XML and/or textfiles that are needed at runtime.

The file folders sits in the same project where they are to be used.

These files are marked as "Copy always" at compile. Build Action is "Content".

On my development machine the files are actually copied into the ./Bin/Release/myFileFolder/xxxxx and all is fine.

On user's computer, install runs fine but some files are reported missing at runtime when the program need them.

Do I miss something? Is any file specific option deep hidden in the option list?

Help please! and .NET framework 3.5


回答1:


If the files are in referenced projects then they are not included in the click once publish by Visual Studio. You can verify this by checking the application files dialog in the publish page of the project properties.

Assuming this is the case to get these files included you can either add them as links in the main project itself or edit the project file to include extra files in the manifest. See ClickOnce Content Files for information on how to do this.




回答2:


A workaround is to make your application create the xml/txt files if they dont exist.



来源:https://stackoverflow.com/questions/5605936/clickonce-file-missing

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!