Hello All,
I store class name and its method into strings.
ie.
String classname = "MyClass1";
String methodname = MyMethod1";
googling and found java.lang.reflect for doing this..
but how to call its method?Code:import java.lang.reflect.*; String classname = "MyClass1"; String methodname = MyMethod1"; Class cp1 = Class.forName(classname);
any help is appreciated..
thanks & regards




Reply With Quote