When I click on Capital Button, it's text changes and the number in WinnerBox changes but the text displayed in r1c1, r1c2, etc is always capital. What is wrong?
private void AlphabetDisplay()
{
if (images == 1)
{
WinnerBox.Text = "1";
r1c1Box.Text = "A";
r1c2Box.Text = "B";
r1c3Box.Text = "C";
r1c4Box.Text = "D";
r2c1Box.Text = "E";
r2c2Box.Text = "F";
r2c3Box.Text = "G";
r2c4Box.Text = "H";
}
if (images == 2)
{
WinnerBox.Text = "2";
r1c1Box.Text = "a";
r1c2Box.Text = "b";
r1c3Box.Text = "c";
r1c4Box.Text = "d";
r2c1Box.Text = "e";
r2c2Box.Text = "f";
r2c3Box.Text = "g";
r2c4Box.Text = "h";
}
if (images == 3)
{
WinnerBox.Text = "3";
r1c1Box.Text = "A";
r1c2Box.Text = "b";
r1c3Box.Text = "C";
r1c4Box.Text = "d";
r2c1Box.Text = "E";
r2c2Box.Text = "f";
r2c3Box.Text = "G";
r2c4Box.Text = "h";
}
}
private void CapitalButton_Clicked(object sender, EventArgs e)
{
if (images == 1)
{
images = 2;
CapitalButton.Text = "Small";
AlphabetDisplay();
return;
}
else if (images == 2)
{
images = 3;
CapitalButton.Text = "Both";
AlphabetDisplay();
return;
}
else if (images == 3)
{
images = 1;
CapitalButton.Text = "Capital";
AlphabetDisplay();
}
What I have tried:
As I said the button text changes, and the WinnerBox text displayed changes. Just no the other boxes.