C# – How to call a static method using reflection

Here’s how to call a static method using reflection: Note: This static method is parameterless. If you have parameters, you have to pass them in like this .Invoke(null, param1, param2). Example – passing static method names to a parameterized unit test With parameterized tests you can only pass in compile-time constants. This means you can’t … Read more C# – How to call a static method using reflection