forum

home / developersection / forums / delegate for any method type - c#

Delegate for any method type - C#

Anonymous User 2900 06-Apr-2013
Hi Everyone!

I want to have a class that will execute any external method, like this:

class CrazyClass
{
  //other stuff

  public AnyReturnType Execute(AnyKindOfMethod Method, 
    object[] ParametersForMethod)
  {
    //more stuff
    return Method(Parameters) //or something like that
  }
}

Is this possible? Is there a delegate that takes any method signature?

c# c# 
Updated on 06-Apr-2013

I am a content writter !


Message
Can you answer this question?

Answer

2 Answers

Liked By