Calling Static Method Using Reflection
I was loading an assembly that contained a class that derived from a class which was defined in my assembly. I wanted to call a static method in that assembly, so I used the Reflection GetMethod and Invoke calls. Then I realized, that the static method was actully a static method of the class defined in my assembly. So instead of using GetMethod and Invoke I could have just called the static method directly.
Would there be a difference?
0 Comments:
Post a Comment
<< Home