title: Changing AppBarButton Icon
body: <p>In my Windows 10 universal application I've Got a AppBarButton in a page:</p>
  
  <pre><code>&lt;AppBarButton x:Name="PinBtn" Icon="Pin" Click="PinBtn_Click"/&gt;
  </code></pre>
  
  <p>I want to check if <code>Icon="Pin"</code> then UnPin it and vice versa.</p>
  
  <p>So I tried to code like this:</p>
  
  <pre><code>  private void PinBtn_Click(object sender,RoutedEventArgs e)
      {
          if(PinBtn.Icon == new SymbolIcon((Symbol.Pin)))
          {
              PinBtn.Icon = new SymbolIcon(Symbol.UnPin);
          }
          else {
              PinBtn.Icon = new SymbolIcon(Symbol.Pin);
          }
      }
  </code></pre>
  
  <p>Problem : <code>(PinBtn.Icon == new SymbolIcon((Symbol.UnPin)))</code> always return <strong>FALSE</strong></p>
  
  <p>What's the problem and fix for it?</p>