Check if a character in a string is a 1 or a 0
<p>I am recieveing a string via a com port that looks like this *000000, or *110101, or anything in between. Each character represents the status of a relay on a PCB I have and the first character after the asterisk represents the first relay and so on. I need to check each character seperatly if it is a 1 or a 0 and then set a label to either ON or OFF accordingly. </p>

<p>My code would be something like this:</p>

<pre><code>if(char 1 == "1")
{

    label4.Text = "ON";    
}
else
{
    label4.Text = "OFF";
}
</code></pre>

<p>and so on down the line for all 6 characters. But I don't know how to seperate each character.</p>

<p>Thanks!</p>
