我收到有关缺少参考的运行时错误。
“System.Object”类型是在未引用的程序集中定义的。您必须添加对程序集 'System.Runtime, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' 的引用
我正在使用 MVC 应用程序并在我的代码中使用 CSharpCodeProvider。
我没有收到任何编译错误,但compileResult
由于上述原因出现运行时错误?
CompilerResults results = provider.CompileAssemblyFromSource(parameters, code);
我什assemblies
至在同样的错误之后添加了标签。web.cofig
有什么线索吗?
<assemblies>
<add assembly="System.Runtime, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
</assemblies>