Configure export options in Crystal Report Viewer

I am using SAP Crystal reports in Visual Studio 2010. I want to customize the viewing of Crystal Report reports export. That is, I want to show only export in pdf, and succeed in my Crystal Report reader.
How can i do this

+4
source share
3 answers

You can restrict ReportViewer to 13.0.x using:

ReportViewer.AllowedExportFormats = (int)(ViewerExportFormats.ExcelFormat | ViewerExportFormats.PdfFormat); 
+4
source

First of all, include the namespace below on top of the code:

using CrystalDecisions.Shared;

then write below code in the page load event as:

protected void Page_Load (object sender, EventArgs e) {

  CrystalReportViewer2.AllowedExportFormats = (int) (ViewerExportFormats.ExcelRecordFormat | ViewerExportFormats.PdfFormat); } 
+3
source

this.crystalReportViewer1.AllowedExportFormats = (int) CrystalDecisions.Shared.ViewerExportFormats.PdfFormat;

+1
source

Source: https://habr.com/ru/post/1390413/


All Articles