Webreport - data from memorystream
Hi,I loaded webreport from SQL and save it to the Memorystream. And i need to show data in webreport on webpage(NOT SAVE TO FILE..).
My code:
Webreport webreport=new Webreport();
webreport.Report.RegisterData(ds, "prodejDataSet");
webReport.ReportFile= //This i need to load the Memorystream - stream
webReport.Report.Prepare();
.....
Have you any ideas?
My code:
Webreport webreport=new Webreport();
webreport.Report.RegisterData(ds, "prodejDataSet");
webReport.ReportFile= //This i need to load the Memorystream - stream
webReport.Report.Prepare();
.....
Have you any ideas?
Comments
MemoryStream ms;
using (SqlCommand cmd = new SqlCommand("Select RPT from TEMPRPT where IDX=@IDX", DBcon))
{
cmd.Parameters.Add("@IDX", SqlDbType.Int).Value = IDX;
var varArray = (Byte[])cmd.ExecuteScalar();
ms = new MemoryStream(varArray);
WebReport1.CurrentTab.Report.LoadPrepared(ms);
WebReport1.ReportDone = true;
}