Calling Reports Through .NET from Reporting Server:
To Load a server Report in web page directly is not possible. By taking a ReportViewer
control we can show the Report in web page.
The ReportViewer control is available in ToolBox under Data Controls Tab.
<rsweb:ReportViewer ID="ReportViewer1" runat="server" ProcessingMode="Remote">
<ServerReport ReportServerUrl=http://ServerName/ReportServer ReportPath="/ReportsFolder/ReportName" />
</rsweb:ReportViewer>
The ProcessMode of ReportViewer Represents weather the Report is Server Report or
Local Report.
To load Report from Reporting Server set the ReportViewer attribute ప్రోసుస్సింగ్మోడే property to Remote as ProcessingMode="Remote"
To load Report from Local set the ReportViewer attribute ProcessingMode property to Local as ProcessingMode="Local"
Requesting a Server Report in C#:
ReportViewer1.ProcessingMode = Microsoft.Reporting.WebForms.ProcessingMode.Remote;
ReportViewer1.ServerReport.ReportServerUrl =new
Uri(http://ServerName/ReportServer);
ReportViewer1.ServerReport.ReportPath = "/ReportsFolder/ReportName";
For Windows applications The processing mode is set as follows
ReportViewer1.ProcessingMode =Microsoft.Reporting.WinForms.ProcessingMode.Remote;
No comments:
Post a Comment