C# FAQ: Why do I get a syntax error when I try to declare a variable named checked?

Microsoft .NET Framework, ASP.NET, Visual C# (CSharp, C Sharp, C-Sharp) Developer Training, Visual Studio


Jump to: navigation, search
CSharp-Online.NET:FAQs
edit

Why do I get a syntax error when I try to declare a variable named checked?

The word checked is a C# keyword. Keywords cannot be used as names. Consult Appendix C. C# Keywords.



Personal tools