Click here to Skip to main content
15,881,881 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
XML
i try to show ssrsc reports in asp.net web page and for this i search tutorials and i find tutorials which shows me add script manager ,reportviewer and a button when i add these 3 things in my project in .aspx page and then when i debug my project then it shows me error and here i clear that i can not add ajax tool kit reigster assembly in .aspx page for this how i add register assebly for ajax code

<%@ Register assembly="Microsoft.ReportViewer.WebForms, Version=9.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" namespace="Microsoft.Reporting.WebForms" tagprefix="rsweb" %>
<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
    <div align ="center" class="adminform">
<br /><br />
        <center>
        <div class="vpb_main_wrapper"  align="center" style="left: inherit"/><br clear="all"/>
            <asp:ScriptManager ID="ScriptManager1" runat="server">

          <asp:Button ID="Button1" runat="server" onclick="Button1_Click" Text="Button" />

            <rsweb:ReportViewer ID="ReportViewer2" runat="server" Height="261px"
                Width="476px">
            </rsweb:ReportViewer>
               </asp:ScriptManager>
    </center>
    </div>

</asp:Content>

Error

Type 'System.Web.UI.ScriptManager' does not have a public property named 'Button'.

Source Error:


Line 11:             <asp:ScriptManager ID="ScriptManager1" runat="server">
Line 12:
Line 13:           <asp:Button ID="Button1" runat="server" onclick="Button1_Click" Text="Button" />
Line 14:
Line 15:             <rsweb:ReportViewer ID="ReportViewer2" runat="server" Height="261px"
Posted
Updated 10-May-20 2:30am

You should not put anything between the ScriptManager Tag .

Use
XML
<asp:ScriptManager ID="ScriptManager1" runat="server">
            </asp:ScriptManager>


And move the Controls outside of it.
 
Share this answer
 
Comments
Diya Ayesa 2-Feb-14 7:43am    
thanku
JoCodes 2-Feb-14 7:50am    
My Pleasure
Your coude should look like this:
ASP.NET
<asp:scriptmanager id="ScriptManager1" runat="server" xmlns:asp="#unknown"></asp:scriptmanager>
 
<asp:button id="Button1" runat="server" onclick="Button1_Click" text="Button" xmlns:asp="#unknown" />

<rsweb:reportviewer id="ReportViewer2" runat="server" height="261px" width="476px" xmlns:rsweb="#unknown"></rsweb:reportviewer>
 
Share this answer
 
Comments
Diya Ayesa 2-Feb-14 7:43am    
thanku

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900