Why i ned to use static classes
for example i set all classes to public when i need to set classes to static
2 Answers
Know the answer? Post it. Somebody with the same question will find it here.
Know the answer? Post it. Somebody with the same question will find it here.
Answer a question in the forums and earn +20 SHARP for every answer.
See unanswered questions
DevSocialUpcoming · 3rd editionAI Agents ConferenceDec 1–3, 2026Live onlineFree to attend5days leftRegister
Manoj BhoirRank #599 · 4K reputationPosted Apr 26, 2015, 6:06 AM EDT
Making a class static just prevents people from trying to make an instance of it. If all your class has are static members it is a good practice to make the class itself static.
Fore more information about static class please see these links :
Static Classes and Static Class Members (C# Programming Guide)
https://msdn.microsoft.com/en-us/library/79b3xss3.aspx
Static Keyword Demystified
http://www.codeproject.com/Articles/15269/Static-Keyword-Demystified
Abhineet SrivastavaRank #1,890 · 783 reputationPosted Apr 26, 2015, 9:03 AM EDT