c# pass method as parameter code example
Example: c# pass method as parameter
public int Method1(string input)
{
return 0;
}
public bool RunTheMethod(Func<string, int> myMethodName)
{
int i = myMethodName("My String");
return true;
}
public bool Test()
{
return RunTheMethod(Method1);
}