我有以下代码:
private Ext.Net.Store getStore(string name)
{
return (Ext.Net.Store)DUOSPage.FindControl(name);
}
和
getStore("store").DataSource = someList;
我可以验证页面中确实存在“store”对象和“someList”。在我看来,找不到 FindControl。但是,我得到了一个
someList = Count = Cannot evaluate expression because a thread is stopped at a point where garbage collection is impossible, possibly because the code is optimized.
以及本地服务器崩溃。对我来说,这意味着该元素可能在页面中并且可以找到,但它会以某种方式导致服务器崩溃和崩溃。
关于这里有什么问题的任何想法?为什么这会使 ASPX 服务器崩溃?
编辑:
错误提示给了我这个:
Description:
Stopped working
Problem signature:
Problem Event Name: CLR20r3
Problem Signature 01: webdev.webserver20.exe
Problem Signature 02: 10.0.0.0
Problem Signature 03: 4ba204ca
Problem Signature 04: ****
Problem Signature 05: 1.0.0.0
Problem Signature 06: 4fe36c1c
Problem Signature 07: 3ce
Problem Signature 08: c
Problem Signature 09: System.NullReferenceException
OS Version: 6.1.7601.2.1.0.256.4
Locale ID: ****