Windows Phone 8.1 comparing Control.Content giving wrong result
<p>I'm experiencing a really weird problem I have the following piece of code :</p>

<pre><code>for (int i = 0; i &lt; Board.Length - 2; i++)
{
    var a = Board[i].Content;
    var b = Board[i + 1].Content;
    var c = Board[i + 2].Content;
    if (a == b &amp;&amp; a == c &amp;&amp;
        (string) a != string.Empty &amp;&amp; a != null)
    {
        MessageDialog msd = new MessageDialog("test");
        await msd.ShowAsync();
    }
}
</code></pre>

<p>Where <code>Board</code> is an array of buttons and a,b,c have the same value of "1". However when comparing them in the if statement they all give false ? The other statements where I check if the string is empty or null give value of true.</p>