如何清除以下錯誤:如何清除錯誤
Only one instance of a ScriptManager can be added to the page. Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Exception Details: System.InvalidOperationException: Only one instance of a ScriptManager can be added to the page.
Source Error: An unhandled exception was generated during the execution of the current web request.
Information regarding the origin and location of the exception can be identified using the exception stack trace below.
以下是我的HTML標記:
<%@ Page Language="C#" AutoEventWireup="true" MasterPageFile="~/MasterPage.master"
CodeFile="ManualReport.aspx.cs" Inherits="ManualReport" %>
<%@ Register assembly="Telerik.Web.UI" namespace="Telerik.Web.UI"
tagprefix="telerik" %>
<asp:Content ContentPlaceHolderID="ContentPlaceHolder1" runat="server"
ID="ContentPlaceHolder1">
<%@ Register Assembly="Microsoft.ReportViewer.WebForms, Version=9.0.0.0,
Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"
Namespace="Microsoft.Reporting.WebForms" TagPrefix="rsweb" %>
<form id="mainform" runat="server"><table width="100%" >
<asp:ScriptManager ID="ScriptManager2" runat="server">
</asp:ScriptManager>
<asp:ScriptManager ID="ScriptManager1" runat="server">
</asp:ScriptManager>
</form>
<div>
<tr><td>Customer Name</td><td>
<asp:RadioButton ID="rdbcustomerAll" runat="server" Visible ="false"
GroupName="CustomerValidation"
Text="All" Checked="false" /></td><td>
<asp:RadioButton ID="rdbcustomerSpecific" runat="server"
GroupName="CustomerValidation" Visible="false" Text="Spec" Checked="true" /></td></
td><td>
<asp:DropDownList ID="cmbName" runat="server">
</asp:DropDownList></td></tr>
<tr><td>Date</td><td><asp:RadioButton ID="rdbDateAll" runat="server"
Visible ="false" GroupName="DateValidation"
Text="All" /></td><td>
<asp:RadioButton ID="rdbDateSpec" runat="server" Visible ="false" Checked="true" GroupName="DateValidation" Text="Spec" /></td><td>
<telerik:RadDatePicker ID="rdpDate" runat="server" xmlns:telerik="telerik.web.ui">
</telerik:RadDatePicker>
</td></tr>
你有一個嚴重的問題,構建您的ASPX標記。這超出了'ScriptManager'重複的問題。我相信你需要閱讀一些關於asp.net的教程。其中很多... – 2011-06-04 06:25:11