TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
Vasanth Natarajan
1.3k
420
47.1k
How to convert the .rpt to PDF Using c#?
Jul 15 2017 2:58 AM
I facing the Problem for converting the RPT to PDF (or) EXCEL Missing parameter!!
Here by My code
ReportDocument cryRpt = new ReportDocument();
ExportOptions CrExportOptions;
cryRpt.Load(strpaths);//my rpt file
DiskFileDestinationOptions CrDiskFileDestinationOptions = new DiskFileDestinationOptions();
ExcelFormatOptions CrFormatTypeOptions = new ExcelFormatOptions();
CrDiskFileDestinationOptions.DiskFileName = "c:\\csharp.net-informations.xls";
CrExportOptions = cryRpt.ExportOptions;
CrExportOptions.ExportDestinationType = ExportDestinationType.DiskFile;
CrExportOptions.ExportFormatType = ExportFormatType.Excel;
CrExportOptions.DestinationOptions = CrDiskFileDestinationOptions;
CrExportOptions.FormatOptions = CrFormatTypeOptions;
cryRpt.SetDatabaseLogon(UserName, Password, ServerName, DatabaseName);
cryRpt.DataSourceConnections[0].IntegratedSecurity = false;
crystalReportViewer1.ReportSource = cryRpt;
cryRpt.ExportToDisk(ExportFormatType.Excel, "c:\\csharp.net-informations.xls");
I want to set the Parameter only in Crystalreport viewer after that i will convert the PDF or Excel file based on the parameter
Reply
Answers (
2
)
How to print rdlc report with custom page size
How to stop the crystal report Login page