Code to export crystal report to pdf directly //Declare Reportdocument Object ReportDocument rpt=new ReportDocument(); //set a ReportPath and assign the dataset to reportdocument object rpt.Load(Server.MapPath("Report1.rpt")); rpt.SetDataSource(ds); //assign the values to crystal report viewer CrystalReportViewer1.ReportSource = rpt; CrystalReportViewer1.DataBind(); //Exporting PDF MemoryStream oStream; // using System.IO oStream = (MemoryStream) rpt.ExportToStream(CrystalDecisions.Shared.ExportFormatType.PortableDocFormat); Response.Clear(); Response.Buffer = true; Response.ContentType = "application/pdf"; Response.BinaryWrite(oStream.ToArray()); Response.End();
ERP Project Management,Asp.net,PL SQL Tips for error resolution,Research,Software Errors and solution,SQL 2014,2012,2008,Procedural language,SP,Power BI,excel macro ,Musical notations,Business software,Degree, diploma related informations.