switch(s) { case "A": A(); break; case "B": B(); break; case "C": C(); break; default: break; }
object obj = new object(); Type t = Type.GetType(""); obj = t.GetProperty("Instance").GetValue(obj, null); t.GetMethod("add").Invoke(obj, new object[] { 1 });
MethodInfo mi = this.GetType().GetMethod("A");
if(mi != null)
{
mi.Invoke(this, null);
}
switch(s)
{
case "A":
A();
break;
case "B":
B();
break;
case "C":
C();
break;
default:
break;
}
Type t = Type.GetType("");
obj = t.GetProperty("Instance").GetValue(obj, null);
t.GetMethod("add").Invoke(obj, new object[] { 1 });