Hello,
we have a problem that needs to get solved urgently.
We use StiViewerControl to show previews of our reports. We face the problem that by the time we print 2 different mrt-files the second one is not displayed correctly.
The page size is still A4 but the font is far too big. Can you please look into the attached screenshot? The first report is correct - the second is completely wrong.
br
joro
Problem with StiViewerControl
Problem with StiViewerControl
- Attachments
-
- previewProblem.jpg (99.2 KiB) Viewed 1724 times
Re: Problem with StiViewerControl
I've found a hint:
Our first report has "millimeter" as report units.
Our second report has "centimeter" as report units.
Our first report has "millimeter" as report units.
Our second report has "centimeter" as report units.
Re: Problem with StiViewerControl
Hello,
In this case, you need set the similar Report unit for both reports.
For example:
Thank you.
In this case, you need set the similar Report unit for both reports.
For example:
Code: Select all
var report1 = new StiReport();
report1.Load("d:\\report1.mrt");
report1.Render();
var report2 = new StiReport();
report2.Load("d:\\report2.mrt");
report2.ReportUnit = report1.ReportUnit;
report2.Render();
var rep = new StiReport();
rep.Render();
rep.RenderedPages.Clear();
rep.IsRendered = true;
foreach(StiPage page in report1.RenderedPages)
{
rep.RenderedPages.Add(page);
}
foreach (StiPage page in report2.RenderedPages)
{
rep.RenderedPages.Add(page);
}
rep.Show();