Answers for "c# get class name as string"

C#
-2

c# get class name as string

// in c# 6.0 you can use nameof(ClassName)
// in older versions you may use typeof(ClassName).Name
// example:
public static class ClassName
{
  public static void PrintName => Console.WriteLine(nameof(ClassName));
}
Posted by: Guest on August-26-2020

Code answers related to "c# get class name as string"

C# Answers by Framework

Browse Popular Code Answers by Language