Note that there are some explanatory texts on larger screens.

plurals
  1. POPrevent Background task from updating LiveTile
    primarykey
    data
    text
    <p>I really need your help since I have a frustrating problem. I'm downloading data in my periodic agent (OnInvoke). Works fine but every night the web site I download data from has no data to download. If that happens I want the live tile to remain as it is (instead of beeing empty) with the current data and not get updated. Then one or two hours later when there is data to download and parse the update should continue.</p> <p>I have tried this but when NotifyComplete is called the the code after still gets executed. Isn't NotifyComplete supposed to stop the rest of the code to be executed?</p> <pre><code>MatchCollection matchesMyData = rxMyData.Matches(strHTML); foreach (Match matchMyData in matchesMyData) { GroupCollection groupsMyData = matchMyData.Groups; //Code for handling downloaded data } if (matchesMyData.Count &lt; 1) { ShellToast toast = new ShellToast(); toast.Title = "No update: "; toast.Content = "Webservice returned no data"; toast.Show(); NotifyComplete(); } </code></pre> <p>I also tried the following peice of code but that stopped my background task and I had to start my app again to re-enable it. Why?</p> <pre><code>ShellTile TileToFind = ShellTile.ActiveTiles.FirstOrDefault(x =&gt; x.NavigationUri.ToString().Contains("TileID=2")); if (TileToFind != null &amp;&amp; intCount &gt; 0) { //Update the live tile } </code></pre> <p>So, when no data gets parsed the tile should remain as it is and an hour or two later when data gets downloaded everything should be back to normal with thetile beeing updated.</p> <p>Please help, since this is a show stopper right now. Thanks in advance.</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload