1
Answer

Why does the radio button ".Checked" result in an error?

xaml:

             <RadioButton x:Name="gRBuEradicatedBlueCities" 
                               Margin="3,0,0,0"
                               Foreground="#000000" 
                               Background="#0000ff" 
                               Click="gRBuEradicatedBlueCities_Click" 
                               />

C#:

           gRBuEradicatedBlueCities.Background = (SolidColorBrush)(new BrushConverter().ConvertFrom("#0000ff"));
            gRBuEradicatedBlueCities.Checked = false;

Why does the radio button ".Checked" result in an error?

Error	CS0079	The event 'ToggleButton.Checked' can only appear on the left hand side of += or -=

Answers (1)