C# MethodInfo getReturnType
-
06-07-2019 - |
Question
I created an instance of MethodInfo:
MethodInfo theMethod = typeof(Reciever).GetMethod("methodName", parameterTypes);
Now I want to know if theMethod's return type is void. How?
Solution
Easy:
theMethod.ReturnType == typeof(void)
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow