Question on putting xml data into the report built from xml only
Posted: Thu May 03, 2007 10:50 am
Hi !
As we continue to integrate StimulSoft in our product, we have 2 new questions.
1- We see you release new builds continuously and we were told that you had fixed an issue with images from text while text.lenght was 0. We would like to have that fix in our engine to have better stability, but we didn't find any procedure of how to install those dlls.
2- We create our reports templates using our exported xml data only. When we then use the template to populate the report with a new xml and send it to printer, it keeps showing the data that was used while making the template. The code i'm using right now is below, what else can i try to have the new data in the report instead of the old ? I write down the xml used for the printing in a file and the xml data is fine, it's the report that doesn't get it.
Thanks for your great support !
Sacha
**************
private static StiReport InitializeReport(MemoryStream xmlData, PrintSessionInfo sessionInfo)
{
StiReport stiReport = new StiReport();
StiOptions.Engine.GlobalEvents.GetValue += new Stimulsoft.Report.Events.StiGetValueEventHandler(OnGetValue);
StiOptions.Engine.HideExceptions = false;
StiOptions.Engine.HideMessages = false;
StiOptions.Engine.LogEnabled = true;
StiOptions.Engine.TraceEnabled = true;
xmlData.Position = 0;
DataSet dataset = new DataSet();
dataset.ReadXml(xmlData);
stiReport.Load(sessionInfo.SummaryReportPath);
stiReport.Dictionary.DataStore.Clear();
stiReport.RegData(dataset);
stiReport.Dictionary.Synchronize();
//Set page orientation if not a custom report
if(!sessionInfo.IsCustomSummaryReport)
{
foreach(StiPage page in stiReport.Pages)
{
page.Orientation = sessionInfo.IsLandscape ? StiPageOrientation.Landscape : StiPageOrientation.Portrait;
}
}
stiReport.PrinterSettings.ShowDialog = false;
stiReport.Compile();
stiReport.CompiledReport.Rendering += new EventHandler(OnRendering);
stiReport.Render(false);
return stiReport;
}
And then call print on the report.
As we continue to integrate StimulSoft in our product, we have 2 new questions.
1- We see you release new builds continuously and we were told that you had fixed an issue with images from text while text.lenght was 0. We would like to have that fix in our engine to have better stability, but we didn't find any procedure of how to install those dlls.
2- We create our reports templates using our exported xml data only. When we then use the template to populate the report with a new xml and send it to printer, it keeps showing the data that was used while making the template. The code i'm using right now is below, what else can i try to have the new data in the report instead of the old ? I write down the xml used for the printing in a file and the xml data is fine, it's the report that doesn't get it.
Thanks for your great support !
Sacha
**************
private static StiReport InitializeReport(MemoryStream xmlData, PrintSessionInfo sessionInfo)
{
StiReport stiReport = new StiReport();
StiOptions.Engine.GlobalEvents.GetValue += new Stimulsoft.Report.Events.StiGetValueEventHandler(OnGetValue);
StiOptions.Engine.HideExceptions = false;
StiOptions.Engine.HideMessages = false;
StiOptions.Engine.LogEnabled = true;
StiOptions.Engine.TraceEnabled = true;
xmlData.Position = 0;
DataSet dataset = new DataSet();
dataset.ReadXml(xmlData);
stiReport.Load(sessionInfo.SummaryReportPath);
stiReport.Dictionary.DataStore.Clear();
stiReport.RegData(dataset);
stiReport.Dictionary.Synchronize();
//Set page orientation if not a custom report
if(!sessionInfo.IsCustomSummaryReport)
{
foreach(StiPage page in stiReport.Pages)
{
page.Orientation = sessionInfo.IsLandscape ? StiPageOrientation.Landscape : StiPageOrientation.Portrait;
}
}
stiReport.PrinterSettings.ShowDialog = false;
stiReport.Compile();
stiReport.CompiledReport.Rendering += new EventHandler(OnRendering);
stiReport.Render(false);
return stiReport;
}
And then call print on the report.