title: Dynamically changing background color
body: <p>In my Windows Phone 7 app, I want <code>ContentPanel</code>'s background to change its color within a specified time (3 seconds in this case). Basically I want it to be "<strong>flashing</strong>". </p>
  
  <p>But the problem is that the changes do not appear while the loop is working, the color changes only once, after the loop is done working. Why?</p>
  
  <pre><code>byte R;
  TimeSpan ts = new System.TimeSpan(0, 0, 0, 3);
  DateTime dt1 = new DateTime();           
  DateTime dt2 = new DateTime();    
  
  requirement = true;
  while (requirement)
  { 
      R = Convert.ToByte(0.5 * 255 * (1 + Math.Sin(DateTime.Now.Millisecond)));
      ContentPanel.Background = new SolidColorBrush(Color.FromArgb(255, R, 125, 70));
      dt1 = DateTime.Now;
      dt2 = DateTime.Now;
      dt2.Subtract(dt1);
      if (dt2.Subtract(ts).CompareTo(dt1) &gt; 0) requirement = false;
   }
  </code></pre>
  
  <p>Is it even possible?</p>