.Net → ASP.Net – Crystal Report Viewer & AJAX
July 31st, 2009 by Ryan Alford
I ran across this issue with the Crystal Report Viewer not printing or exporting if it was inside of an AJAX UpdatePanel. It seems that the Crystal Report Viewer is required to do a synchronous postback to be able to print or export.
You will need to add the Triggers as shown below to the UpdatePanel, or remove it from the UpdatePanel all together.
<asp:UpdatePanel ID="UpdatePanel1" runat="server">
<Triggers>
<asp:PostBackTrigger ControlID="CrystalReportViewer1" />
</Triggers>
<ContentTemplate>
<CR:CrystalReportViewer ID="CrystalReportViewer1" runat="server" AutoDataBind="true" />
</ContentTemplate>
</asp:UpdatePanel>