反射

            Type t = parentFrom.GetType();
            
             object showPage = Activator.CreateInstance(t);
            MethodInfo methodInfo = t.GetMethod("ShowPage");
            methodInfo.Invoke(showPage, 
                              new object[] {
                                              currentPage     
                                            });

你可能感兴趣的:(反射)