[英]System.TypeLoadException (WebPartsZone) in mono
I load a user control in a web page which throws an exception: 我在网页中加载了一个用户控件,这引发了异常:
this.LoadControl(someusercontrol); // throws TypeLoadException
The details : 细节 :
System.Reflection.ReflectionTypeLoadException: The classes in the module cannot be loaded.
at (wrapper managed-to-native) System.Reflection.Assembly:GetTypes (bool)
at System.Reflection.Assembly.GetTypes ()
...
in /usr/src/packages/BUILD/mono2.4.2.3/mcs/class/System.Web/System.Web.Compilation/BuildManager.cs:864
Error message: 错误信息:
"could not load type 'System.Web.UI.WebControls.WebParts.WebPartsZone from assembly 'System.Web, Version=2.0.0.0 ..."
I get it that WebPartsZone is not implemented in System.Web. 我知道WebPartsZone没有在System.Web中实现。 What I do not get is why does it try to load that.
我不明白的是为什么它试图加载它。 I'm not using WebParts in my webpage, or in my control .
我没有在网页或控件中使用WebParts 。
How can I find WHO (or WHAT) is calling/using WebPartsZone ? 如何找到WHO(或WHAT)正在调用/使用WebPartsZone? A simple "find in files" search for "webparts" returns no finds.. so what next?
一个简单的“查找文件”搜索“ webparts”不会返回任何结果。
Edit: I'm using ajax control toolkit 3.5 .. MOMA says gives a warning about this assembly using the webparts... is it possible that asp:Panel or asp:UpdatePanel uses a webpart somewhere ? 编辑:我正在使用ajax控件工具包3.5 .. MOMA说使用webparts发出有关此程序集的警告... asp:Panel或asp:UpdatePanel是否有可能在某处使用webpart? Last I heard, Ajaxcontroltoolkit was working under Mono , right?
最后我听说,Ajaxcontroltoolkit在Mono下工作,对吗?
I ran grep -rHin webparts in the source of the control toolkit and there are a few controls that have a using System.Web.UI.WebControls.WebParts
in them (MaskedEdit, TabPanel,...). 我在控件工具箱的源代码中运行了grep -rHin Webparts ,其中有一些控件
using System.Web.UI.WebControls.WebParts
(MaskedEdit,TabPanel等)。
However, I just built the AjaxControlToolkit.dll assembly from those sources in mono (I'm using subversion trunk, which is quite close to the soon to be release 2.6) and it built fine. 但是,我只是从那些源中以单声道形式构建了AjaxControlToolkit.dll程序集(我正在使用Subversion干线,这与即将发布的2.6版本非常接近),并且它的构建很好。 I can even run the demo with all the controls (SampleWebSite folder) without a problem... I think that some controls have the
using
for WebParts but none is actually using any type from that namespace. 我什至可以用所有控件(SampleWebSite文件夹)运行演示,都没有问题...我认为某些控件具有用于WebParts的功能,但实际上没有一个控件
using
该名称空间中的任何类型。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.