将忽略TileNotification与临时文件夹中的图像 [英] TileNotification with image from temporary folder is ignored
问题描述
我正在尝试使用临时图像创建TileNotification,如下所示:
var Notifications = Windows.UI.Notifications; var tileUpdater = Notifications.TileUpdateManager.createTileUpdaterForApplication(); tileUpdater.enableNotificationQueue(true); var tileXml = Notifications.TileUpdateManager.getTemplateContent(Notifications .TileTemplateType.tileWideImage); var tileImageAttributes = tileXml.getElementsByTagName(" image"); tileImageAttributes [0] .setAttribute(" src"," ms-appdata:/// temp /" + filename); tileImageAttributes [ 0] .setAttribute(" alt",filename); var tileNotification = new Notifications.TileNotification(tileXml); tileUpdater.update(tileNotification);
但它不起作用,没有例外。
如果我使用ms-appdata:/// local /而不是问题。有什么想法?
谢谢!
Juanma
Juan Manuel Servera
twitter: @jmservera
mi blog: http://jmservera.wordpress.com
$ b $bÚneteal grupo de WP7 en LinkedIn
MCPD WP7开发人员 - MCTS Sharepoint 2010应用程序开发
临时文件夹可能被清除? 您可以使用进程监视器查看尝试读取此文件夹时发生的文件活动。
http://technet.microsoft.com/en-us/sysinternals/bb896645
-Jeff
Hi,
I'm trying to create a TileNotification using a temporary image, something like this:
var Notifications = Windows.UI.Notifications;var tileUpdater = Notifications.TileUpdateManager.createTileUpdaterForApplication();tileUpdater.enableNotificationQueue(true);var tileXml = Notifications.TileUpdateManager.getTemplateContent( Notifications.TileTemplateType.tileWideImage);var tileImageAttributes = tileXml.getElementsByTagName("image");tileImageAttributes[0].setAttribute("src", "ms-appdata:///temp/"+filename);tileImageAttributes[0].setAttribute("alt", filename);var tileNotification = new Notifications.TileNotification(tileXml);tileUpdater.update(tileNotification);
But it does not work, no exceptions.
If I use ms-appdata:///local/ instead it works without problems. Any idea?
Thanks!
Juanma
Juan Manuel Servera
twitter: @jmservera
mi blog: http://jmservera.wordpress.com
Únete al grupo de WP7 en LinkedIn
MCPD WP7 Developer - MCTS Sharepoint 2010 Application Development
The temp folder may be getting cleared? You can use process monitor to see what file activity is occuring when it tries to read this folder.
http://technet.microsoft.com/en-us/sysinternals/bb896645
-Jeff
这篇关于将忽略TileNotification与临时文件夹中的图像的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!