title: Borderless application on maximize is hiding behind the task bar in Win 7 and Win 8
body: <p>I have created a borderless window in WPF. I have written a event to maximize the window but on maximizing, part of the window sometimes hides behind the task bar and after a moment appears on top of the task bar.</p>
  
  <p>How can I ensure that the window remains on top of task bar every time ? Following is the way I have implemented:</p>
  
  <pre><code>private void OnMaximizedClicked(object sender, RoutedEventArgs e)
  {
      this.WindowState = this.WindowState != WindowState.Normal ? WindowState.Normal : WindowState.Maximized;
  }
  </code></pre>
  
  <p>I have tried setting the TopMost property to true, but didn't help me either. </p>