increase performance
Posted: Mon Sep 02, 2013 11:34 am
hi,
I am using below code to generate pdfs passing soa_id one by one.but here to generate 1000 pdfs or htmls its consuming 25 minutes.here its consuming time to compile every time.Is there any alternative ,or reduce code from below.
I have followed links which were sent by you to reduce time in mrt designing. i need the time reducing in .cs
foreach (DataRow DR in ds.Tables[0].Rows)
{
objStiReport.DataSources["Reportvalues"].Parameters["soa_id"].Value = DR["soa_id"].ToString(); //passing arguments
// objStiReport.DataSources["Reportvalues"].Parameters["Addresstype"].Value = "BIL"; //passing arguments
objStiReport.Compile();
objStiReport.Render(true);
StiorderDetail.Report = objStiReport;
StiorderDetail.Report.ExportDocument(StiExportFormat.Html, Server.MapPath("~/Reports/OrderDetails/" + DR["soa_id"].ToString() + "_1.html"), objStiPdfExportSettings); // generating pdf file in a given location
StiorderDetail.Dispose();
}
I am using below code to generate pdfs passing soa_id one by one.but here to generate 1000 pdfs or htmls its consuming 25 minutes.here its consuming time to compile every time.Is there any alternative ,or reduce code from below.
I have followed links which were sent by you to reduce time in mrt designing. i need the time reducing in .cs
foreach (DataRow DR in ds.Tables[0].Rows)
{
objStiReport.DataSources["Reportvalues"].Parameters["soa_id"].Value = DR["soa_id"].ToString(); //passing arguments
// objStiReport.DataSources["Reportvalues"].Parameters["Addresstype"].Value = "BIL"; //passing arguments
objStiReport.Compile();
objStiReport.Render(true);
StiorderDetail.Report = objStiReport;
StiorderDetail.Report.ExportDocument(StiExportFormat.Html, Server.MapPath("~/Reports/OrderDetails/" + DR["soa_id"].ToString() + "_1.html"), objStiPdfExportSettings); // generating pdf file in a given location
StiorderDetail.Dispose();
}