简体   繁体   English

创建一个启用AJAX的网站

[英]Creating an AJAX-Enabled Web Site

I'am trying to follow an ASP.NET with AJAX Training. 我正在尝试通过AJAX培训来学习ASP.NET。 At certain moment, they deploy an AJAX-Enabled Web Site. 他们有时会部署一个启用AJAX的网站。 but for me I can't found this option (I'm using Visual Studio 2008). 但对我来说,我找不到此选项(我使用的是Visual Studio 2008)。

Even if I installed the Ajax Control Toolkit it still not working for me !! 即使我安装了Ajax Control Toolkit它仍然对我不起作用!

What must I do to find this ? 我该怎么做才能找到这个?

Even if you can't find the template, you can still do everything the training kit needs. 即使找不到模板,您仍然可以完成培训工具包所需的一切。

The only difference between an ASP.NET web project and an AJAX-enabled ASP.NET web project is that it takes care of a few pre-requisites for you: ASP.NET Web项目和启用AJAX的ASP.NET Web项目之间的唯一区别是,它可以满足您的一些先决条件:

1) It adds a reference to the Ajax control toolkit. 1)它添加了对Ajax控件工具包的引用。 You can do this manually by right-clicking on your project in the Solution Explorer, choosing "Add Reference", and navigating to the AjaxControlToolkit DLL (or find it in under the .NET tab, if you've added it to the GAC). 您可以通过在解决方案资源管理器中右键单击您的项目,选择“添加引用”,然后导航到AjaxControlToolkit DLL来手动完成此操作(如果已将其添加到GAC中,则可以在.NET选项卡下找到它) 。

2) It adds a ScriptManager control to your aspx page. 2)它将ScriptManager控件添加到您的aspx页面。 It comes with the Ajax Control Toolkit. 它带有Ajax Control Toolkit。 The ScriptManager is required to use any of the AJAX Control Toolkit controls. 使用任何AJAX控件工具包控件都需要ScriptManager。 Add it to the top of your page. 将其添加到页面顶部。

If you take care of those two things, you should be good to go - it's the same thing as using the Ajax-enabled website template. 如果您照顾好这两件事,那么您应该会很好-与使用支持Ajax的网站模板一样。

I have an issue in 2nd step. 我在第二步有问题。 As i am using update panel and there is already a ScriptManager in master page, so I am using ScriptManagerProxy in updatepanel. 由于我正在使用更新面板,并且母版页中已经有一个ScriptManager,因此我在updatepanel中使用了ScriptManagerProxy。

So when i start adding "ToolkitScriptManager" it shows error "Two scriptmanager" instances are not possible in one page... 因此,当我开始添加“ ToolkitScriptManager”时,它会显示错误“无法在一页中显示“两个scriptmanager”实例...

Manish Jain 曼尼斯·贾恩(Manish Jain)

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM