title: How to update liveTile programatically on Windows8?
body: <p>I want to update my liveTile when application will enter background.How can I do ??</p>
  
  <p>here is my code to update a liveTile.</p>
  
  <pre><code>    private static TileUpdater updater;        
  
  public static void updateLiveTile(string text)
          {
              if (updater == null)
              {
                  updater = TileUpdateManager.CreateTileUpdaterForApplication();
              }
              else
                  updater.Clear();
  
              updater.EnableNotificationQueue(true);
  
              var tile = TileUpdateManager.GetTemplateContent(TileTemplateType.TileWideImageAndText01);
              tile.GetElementsByTagName("text")[0].InnerText = text;
              XmlNodeList tileImageAttributes = tile.GetElementsByTagName("image");
              ((XmlElement)tileImageAttributes[0]).SetAttribute("src", "ms-appdata:///local/MyShop_Image.png");
              ((XmlElement)tileImageAttributes[0]).SetAttribute("alt", "red graphic");
  
              updater.Update(new TileNotification(tile));
          }
  </code></pre>