Hi All,
I am using telerik webform report viewer version 5.1.11.713 and the corresponding Reporting dll's.
I am having issues with enabling a user to close down a report and continue using the ajaxified web application.
I use the radwindow to load an aspx page that contains the web viewer. In the Page_Load event, I assign my report document to it.
Some reports may take a couple of minutes to run, and the user may close the radwindow in order to do another task. It would be expected that the user not receive the report.
The thing is, if the user clicks a button that uses a callback, that callback waits until the Report has completed.
This is unexpected.
Is this the intent of the Report mechanism? Elsewhere, if a callback is triggered while another callback is being processed, the new callback takes precedence.
Can you please advise as to what can be done to alleviate this issue?
Thanks,
Steele.
My ReportHolder page :
And my code behind :
I am using telerik webform report viewer version 5.1.11.713 and the corresponding Reporting dll's.
I am having issues with enabling a user to close down a report and continue using the ajaxified web application.
I use the radwindow to load an aspx page that contains the web viewer. In the Page_Load event, I assign my report document to it.
Some reports may take a couple of minutes to run, and the user may close the radwindow in order to do another task. It would be expected that the user not receive the report.
The thing is, if the user clicks a button that uses a callback, that callback waits until the Report has completed.
This is unexpected.
Is this the intent of the Report mechanism? Elsewhere, if a callback is triggered while another callback is being processed, the new callback takes precedence.
Can you please advise as to what can be done to alleviate this issue?
Thanks,
Steele.
My ReportHolder page :
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="ReportHolder.aspx.cs" Inherits="Audit.Audit_Reports.ReportHolder" %>
<%@ Register assembly="Telerik.ReportViewer.WebForms, Version=5.1.11.713, Culture=neutral, PublicKeyToken=a9d7983dfcc261be" namespace="Telerik.ReportViewer.WebForms" tagprefix="telerikrv" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<
html
xmlns
=
"http://www.w3.org/1999/xhtml"
>
<
head
runat
=
"server"
>
<
title
>Report Holder</
title
>
<
style
type
=
"text/css"
>
html, body, form#form1, div#Content
{
margin: 0px;
padding: 0px;
height: 100%;
}
</
style
>
</
head
>
<
body
>
<
form
id
=
"form1"
runat
=
"server"
>
<
telerik:RadScriptManager
ID
=
"RadScriptManager1"
runat
=
"server"
>
</
telerik:RadScriptManager
>
<
telerik:RadAjaxManager
ID
=
"RadAjaxManager1"
runat
=
"server"
UpdatePanelsRenderMode
=
"Inline"
>
<
AjaxSettings
>
<
telerik:AjaxSetting
AjaxControlID
=
"ReportViewer1"
>
<
UpdatedControls
>
<
telerik:AjaxUpdatedControl
ControlID
=
"ReportViewer1"
/>
</
UpdatedControls
>
</
telerik:AjaxSetting
>
</
AjaxSettings
>
</
telerik:RadAjaxManager
>
<
telerik:RadCodeBlock
ID
=
"RadCodeBlock1"
runat
=
"server"
>
<
script
type
=
"text/javascript"
>
</
script
>
</
telerik:RadCodeBlock
>
<
telerik:RadSplitter
ID
=
"RadSplitter1"
runat
=
"server"
Height
=
"100%"
Width
=
"100%"
>
<
telerik:RadPane
ID
=
"RadPane1"
Runat
=
"server"
Scrolling
=
"None"
onclientresized
=
"ResizeViewer"
>
<
div
id
=
"Content"
>
<
telerikrv:ReportViewer
ID
=
"ReportViewer1"
runat
=
"server"
Height
=
"100%"
Width
=
"100%"
ShowHistoryButtons
=
"False"
ShowParametersButton
=
"False"
>
</
telerikrv:ReportViewer
>
</
div
>
</
telerik:RadPane
>
</
telerik:RadSplitter
>
</
form
>
</
body
>
</
html
>
And my code behind :
using
System;
using
System.Collections.Generic;
using
System.Linq;
using
System.Web;
using
System.Web.UI;
using
System.Web.UI.WebControls;
namespace
Audit.Audit_Reports
{
public
partial
class
ReportHolder : System.Web.UI.Page
{
private
Telerik.Reporting.IReportDocument Get_Report(
string
RepName)
{
try
{
Type t = Type.GetType(
"Audit.Audit_Reports."
+ RepName);
Telerik.Reporting.IReportDocument ret = (Telerik.Reporting.IReportDocument)(Activator.CreateInstance(t));
foreach
(
string
QRKey
in
Request.QueryString.Keys)
{
if
(QRKey !=
"Report"
)
{
// Is a parameter to set
Telerik.Reporting.Report rep = (Telerik.Reporting.Report)ret;
if
(rep.ReportParameters.Contains(QRKey))
{
rep.ReportParameters[QRKey].Value = Request.QueryString[QRKey];
}
}
}
return
ret;
}
catch
(Exception oE)
{
return
null
;
}
}
protected
void
Page_Load(
object
sender, EventArgs e)
{
if
(!IsPostBack)
{
Telerik.Reporting.IReportDocument rd = Get_Report(Request.QueryString[
"Report"
]);
if
(rd !=
null
)
{
ReportViewer1.Report = rd;
this
.Title = rd.DocumentName;
ReportViewer1.ShowParametersButton =
true
;
}
}
}
}
}