Get the Controller Name and Method Name in ASP.NET-Core 2.2 Controller
You have access to controller name in the
ControllerContext.ActionDescriptor.ControllerName
property, given that the action descriptor is of ControllerActionDescriptor
type
Reference ControllerActionDescriptor.ControllerName
I know It's late but maybe someone can benefit from it
ControllerName: ControllerContext.ActionDescriptor.ControllerName
ActionName: ControllerContext.ActionDescriptor.ActionName