I wanted to toggle a control on a C# Winform, and wrote it this way:
private void chtCPU_Click(object sender, EventArgs e)
{
bool is3d = chtCPU.ChartAreas["ChartArea1"].Area3DStyle.Enable3D;
chtCPU.ChartAreas["ChartArea1"].Area3DStyle.Enable3D = !is3d;
}
Would this be considered a good method for accomplishing this? It seems highly readable, and efficient, but is it good approach?