private static Type GetControlType(Type t) { return GetType(t, new Type[] { typeof(ViewPage<>).MakeGenericType(t), typeof(ViewControl<>).MakeGenericType(t) }, new string[] { "~/Views/{0}.aspx", "~/Views/{0}.ascx" }); }