string assembly = "Ektron.Cms.ObjectFactory.dll";
string asspath = path + "bin\\" + assembly;
Assembly run_obj = Assembly.LoadFrom(@asspath);
paraObj[0] = run_obj.GetType(
"Ektron.Cms.Search.SearchContentProperty",
true,
true
).GetProperty("Language");
string equalExp = "Ektron.Cms.Search.Expressions.EqualsExpression";
Type objclass = run_obj.GetType(equalExp, true, true);
object objObj = Activator.CreateInstance(objclass, paraObj);
Activator.CreateInstance(objclass, paraObj)
引發錯誤:C#反射 - 類型錯誤
System.Reflection.RuntimeParameterInfo can't be implicitly convert into Ektron.Cms.Search.Expresions.PropertyExpression
什麼是'paraObj'在上面的代碼片段? – abhilash 2012-01-10 13:14:58
@ABKolan一個'object []' – 2012-01-10 13:16:58