using CrystalDecisions.CrystalReports.Engine;
ReportDocument rptCust;
string sDate_time;
string sDestination_path;
CrystalDecisions.Shared.ExportOptions myExportOptions;
CrystalDecisions.Shared.DiskFileDestinationOptions File_destination;
CrystalDecisions.Shared.PdfRtfWordFormatOptions Format_options;
myExportOptions = new CrystalDecisions.Shared.ExportOptions();
File_destination = new CrystalDecisions.Shared.DiskFileDestinationOptions();
Format_options = new CrystalDecisions.Shared.PdfRtfWordFormatOptions();
sDate_time = DateTime.Now.ToString("ddMMyyyyHHmmssff");
sDestination_path = sDestination_file + sPolicy_number + sPolicy_number1 + "-" + sDate_time + ".pdf";
File_destination.DiskFileName = sDestination_path;
myExportOptions = rptCust.ExportOptions;
myExportOptions.ExportDestinationType = CrystalDecisions.Shared.ExportDestinationType.DiskFile;
myExportOptions.ExportFormatType = CrystalDecisions.Shared.ExportFormatType.PortableDocFormat;
myExportOptions.DestinationOptions = File_destination;
myExportOptions.FormatOptions = Format_options;
rptCust.Export();
Sunday, October 17, 2010
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment