what possible in a static class and not in non-static class or vice versa in C#, for example
static class
MyProgram.CallFunction();
non-static class
MyProgram obj =new MyProgram();
obj.CallFunction();
in the above example without creating the instance we can able to call static class members so this is basic.
I'm looking for a difference which is possible and not possible in static and non-static

Asad AliRank #1,139 · 1.6K reputationPosted Dec 8, 2019, 9:58 PM EST
If you are using IOC than its better to not to use static classes and let dependency injection hangle it (but that absolutely depends on your situation)
also If you are using TDD then it's easy to create fakes for classes that are non-static
Ashutosh GuptaRank #805 · 2.9K reputationPosted Dec 8, 2019, 5:34 AM EST
Puneet KankarRank #446 · 5.6K reputationPosted Dec 8, 2019, 4:45 AM EST
Dinesh GabhaneRank #265 · 9.5K reputationPosted Dec 8, 2019, 3:42 AM EST