Click here to Skip to main content
15,881,588 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
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.
Posted
Updated 4-Mar-21 17:04pm

1 solution

Add to the styles.xml file in Android project under Resources/Values

<item name="android:textAllCaps">false
 
Share this answer
 
Comments
BillWoodruff 5-Mar-21 2:32am    
How could we guess your app was an Android project ? Use Tags on your questions.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900