title: Scheduling a timed background task in windows 8.1 store app
body: <p>I have a list of of StringsDouble called Messages.</p>
  
  <p>The code for the class is below:</p>
  
  <pre><code>public class StringsDouble
  {
      public string Sender {get; set;}
  
      public string Message {get; set;}
  
      public DateTime Time {get; set;}  
  }
  </code></pre>
  
  <p>every time my app receives a new message. I update the List and i store the time of the latest message sent for the user sending that message.</p>
  
  <p>what i want to do is, every 5 minutes the app should go through the list. </p>
  
  <p>and for every item in the list it should get the time property and get the current system time , and check to see if the difference is more than 30 minutes. If it is, it should delete that item from the list.</p>
  
  <p>How can i accomplish this?</p>
  
  <p>I believe i need to use a background task, but how can i schedule it to run every 5 minutes?</p>