Test

Test

  • NA
  • 17
  • 1k

Windows 10 mobile widelivetile not updating in emulator?

Oct 9 2015 2:05 AM
hi 
  

I am facing problem in updating wide live tile while switching from Square Tile to Wide Tile in windows universal app development. It is working fine in windows surface and Desktop but coming to phone it is not updating Wide tile could any one please help me?

 

NOTE:By default Wide Tile is working fine for us but when we change it from Square Tile to wide tile it is not working in emulator.

Here is our total Sample code:

TileUpdateManager.CreateTileUpdaterForApplication().Clear();

TileUpdateManager.CreateTileUpdaterForApplication().EnableNotificationQueue(true);
var _tileXml = TileUpdateManager.GetTemplateContent(TileTemplateType.TileSquare150x150PeekImageAndText03);
var tileImage = _tileXml.GetElementsByTagName("image")[0] as Windows.Data.Xml.Dom.XmlElement;
tileImage.SetAttribute("src", "ms-appx:///Assets/Logo.png");
var tileText = _tileXml.GetElementsByTagName("text");
(tileText[0] as Windows.Data.Xml.Dom.XmlElement).InnerText = "xyz";
(tileText[1] as Windows.Data.Xml.Dom.XmlElement).InnerText = "ABC";
(tileText[2] as Windows.Data.Xml.Dom.XmlElement).InnerText = "EFGH";
(tileText[3] as Windows.Data.Xml.Dom.XmlElement).InnerText = "IJKL";
var tileNotification = new TileNotification(_tileXml); TileUpdateManager.CreateTileUpdaterForApplication().Update(tileNotification);
 
 
Windows.Data.Xml.Dom.XmlDocument tileXml = TileUpdateManager.GetTemplateContent(TileTemplateType.TileWide310x150PeekImageAndText02);
var tileText1 = tileXml.GetElementsByTagName("text");
(tileText1[0] as Windows.Data.Xml.Dom.XmlElement).InnerText ="xyz";
(tileText1[1] as Windows.Data.Xml.Dom.XmlElement).InnerText = "ABC";
(tileText1[2] as Windows.Data.Xml.Dom.XmlElement).InnerText = "EFGH";
(tileText1[3] as Windows.Data.Xml.Dom.XmlElement).InnerText ="IJKL";
(tileText1[4] as Windows.Data.Xml.Dom.XmlElement).InnerText = "Sample App";
var tileImage = tileXml.GetElementsByTagName("image")[0] as Windows.Data.Xml.Dom.XmlElement;
tileImage1.SetAttribute("src", "ms-appx:///Assets/Wide310x150Logo.Scale-100.png");//Assets\Wide310x150Logo.png
TileUpdateManager.CreateTileUpdaterForApplication().Update(new TileNotification(tileXml));