I don’t like to see a class name that is used as a string parameter, for example “FileDownloader” in the code, and I would like to use something like this FileDownloader.Name (), where FileDownloader is the class name.
The only problem is that I cannot find out how to do this without instantiating an object or creating a static method ...
Is there a way to get the class name in .net without an object instance and without creating a static method that returns the class name?
source
share