简体   繁体   English

发布WPF应用程序后,某些图像不再显示

[英]Some of the images are not coming after Publishing WPF application

I have published my WPF application using ClickOnce publishing method. 我已经使用ClickOnce发布方法发布了WPF应用程序。 I ran the application on the client PC and I noticed that some of my images are not appearing eg Background images of Windows. 我在客户端PC上运行了该应用程序,我发现某些图像没有出现,例如Windows的背景图像。 I looked carefully and found out that one Sample.jpg Photo is properly showing inside the Image container which I've used for every record. 我仔细查看,发现一张Sample.jpg照片正确显示在Image容器内,该容器用于我的每条记录。

Same goes for another image n still coming. 对于另一个仍要出现的图像也是如此。 The problem I am not able to figure out why both these two images are coming and not the background one? 问题我无法弄清楚为什么这两个图像都来了,而不是背景图像呢?

While creating the Application I have put all the images in a single Folder and all images are referenced from this single folder only. 在创建应用程序时,我将所有图像都放在一个文件夹中,并且所有图像仅从该单个文件夹中引用。

I also tried by simply copying my project>BIN folder files to client machine and yes, all images are loaded properly without any issues. 我也尝试过简单地将我的project> BIN文件夹文件复制到客户端计算机,是的,所有图像都正确加载,没有任何问题。 The problem is only coming in the publish version of my application. 问题仅出现在我的应用程序的发布版本中。

Could anyone help me in this? 有人可以帮我吗? are there any settings I should take care of while deploying the application? 部署应用程序时需要注意哪些设置? Or I should move them to any specific location? 还是我应该将它们移至任何特定位置?

您的图像“构建操作”属性是否设置为“内容”,“复制到输出”目录属性是否设置为“始终复制/如果较新则复制”?

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

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