public static void ValueTileUpdater(string value) { _tileContent = GenerateTileContent(value); var notification = new TileNotification(_tileContent.GetXml()); TileUpdateManager.CreateTileUpdaterForApplication().Update(notification); }
public static async Task TileUpdater() { try { var localSettings = Windows.Storage.ApplicationData.Current.LocalSettings; string value = localSettings.Values["oneshot"].ToString(); //var oneshot = true; var x = await DataUsage(); if (x.errorList.Count == 0) { _tileContent = GenerateTileContent(x.usageList[2]); var notification = new TileNotification(_tileContent.GetXml()); TileUpdateManager.CreateTileUpdaterForApplication().Update(notification); // x.usageList[2] = "9.5"; if (x.usageList[2].Contains("9.") && value == "true") { Pronto.PopToast("Your Monthly Data Usage have exceded 9 GB"); localSettings.Values["oneshot"] = "false"; } } else { return; } } catch { return; } }
/// <summary> /// Initializes a new instance of the <see cref="TileContentBuilder"/> class. /// </summary> public TileContentBuilder() { Content = new TileContent(); }