新建网站选择ASP.NET网站,为什么使用AJAX控件就出错,该如何解决

新建网站选择ASP.NET网站,为什么使用AJAX控件就出错
选择ASP.NET网站, 拖一个ScriptManager 和一个UpdatePanel, 然后在UpdatePanel里面放一个Label 和一个 Button
,然后在UpdatePanel里面加入Button的点击事件,点击后 Label1 显示 “使用ajax成功!”,就是一个简单的例子。


但是运行该ASPX页面的时候 报错,“已完毕,但网页上有错误。”  
行 42 和 63
字符 1
错误: ‘Sys’未定义。


如果新建的时候选择 asp.net ajax-enabled web site 就不会有问题


我一个小项目,是asp.net网站为模板的,如今想加入ajax控件,该怎么办呢?

新人分少, 实在不好意思,还请各位帮帮忙。

祝大家国庆愉快!



------解决方案--------------------
修改配置文件:
<compilation debug="true">
<assemblies>
<add assembly="System.Web.Extensions, Version=1.0.61025.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
<add assembly="System.Web.Extensions.Design, Version=1.0.61025.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
<add assembly="System.Design, Version=2.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A"/>
<add assembly="System.Drawing.Design, Version=2.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A"/>

</assemblies>
</compilation>
<!--
通过 <authentication> 节可以配置 ASP.NET 使用的 
安全身份验证模式,
以标识传入的用户。 
-->
<httpHandlers>
<remove verb="*" path="*.asmx"/>
<add verb="*" path="*.asmx" validate="false" type="System.Web.Script.Services.ScriptHandlerFactory, System.Web.Extensions, Version=1.0.61025.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35"/>
<add verb="*" path="*_AppService.axd" validate="false" type="System.Web.Script.Services.ScriptHandlerFactory, System.Web.Extensions, Version=1.0.61025.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35"/>
<add verb="GET,HEAD" path="ScriptResource.axd" type="System.Web.Handlers.ScriptResourceHandler, System.Web.Extensions, Version=1.0.61025.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" validate="false"/>
</httpHandlers>