Question

i m using ASP.NET MVC. now i needed RDLC report so i used reportviewer. but i dont want to use iframe so i did routing in my global.asax

public static void RegisterRoutes(RouteCollection routes)
        {
            routes.IgnoreRoute("{resource}.axd/{*pathInfo}");


            //Custom route for reports
            routes.MapPageRoute(
             "ReportRoute",                         // Route name
             "Reports/{reportname}",                // URL
             "~/CommonReports/{reportname}.aspx"   // File
             );

        }

my jquery code is

$('#hrfItemSoldRpt').live('click', function (e) {
        $.ajax({
            url: '/Retail_MVC/Reports/ReportViewer',
        }).done(function (data) {
            alert(data);
            $("#content").html(data);
        });
    });

now its on my Content but no css apply, no any click its just in disabled format

i got this in alert and also in responce HTML but it gives error

 Your browser does not support scripts or has been configured not to allow scripts

is there any solution please??

Was it helpful?

Solution

If you are asking about loading RDLC report from Jquery ajax then its not possible because RDLC Report is a Asp.net server side control and you are trying to render it as a html from client side.

You need to either use iframe or any other option to fulfill your requirment

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top