Page 1 of 2

Combining reports dynamically - print blanks the report

Posted: Thu Dec 19, 2013 5:40 am
by midspace
We are working on a complex Letters solution, which is supposed to combine Compiled Template's during processing, to create a single Report for the user.
We plan to allow straight through printing, PDF generation, Previewing, and minor editing.

We are having trouble with the Preview. When I try the 'Print' button from the preview, the combined Report disappears, and we are left with a blank report.

We are using 2013.2.1700.0

Attached is a cut down sample of our project in C# WinForms .Net 4.
https://dl.dropboxusercontent.com/u/262 ... ewTest.zip

Re: Combining reports dynamically - print blanks the report

Posted: Fri Dec 20, 2013 7:14 am
by Alex K.
Hello,

We couldn't reproduce this bug.
Please try to check the last build.

Thank you.

Re: Combining reports dynamically - print blanks the report

Posted: Sun Dec 22, 2013 10:39 pm
by midspace
Updated to latest version of Stimulsoft.
Retested issue. The bug still exists.
Pressing the 'print' button causes Report to disappear.

I have attached a video (animated GIF) of the issue.
StimulsoftPrintIssue.gif
StimulsoftPrintIssue.gif (985.92 KiB) Viewed 3291 times

Re: Combining reports dynamically - print blanks the report

Posted: Tue Dec 24, 2013 11:04 am
by HighAley
Hello.

You should add two lines of code to your project:

Code: Select all

            newreport = new StiReport();
            newreport.ReportCacheMode = StiReportCacheMode.On;
            newreport.ReportCachePath = Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.LocalApplicationData), "StimulsoftReportsCache");
            newreport.RenderedPages.CanUseCacheMode = true;
            newreport.RenderedPages.CacheMode = true;
            newreport.RenderedPages.Clear();
            newreport.NeedsCompiling = false;   // add 
            newreport.IsRendered = true;        // add
Without this properties the report is compiled and rendered again. In your case this is the empty report.

Thank you.

Re: Combining reports dynamically - print blanks the report

Posted: Sun Jan 05, 2014 10:14 pm
by midspace
Thank you, that worked great!

Re: Combining reports dynamically - print blanks the report

Posted: Mon Jan 06, 2014 4:06 am
by Andrew
Great!

Have a nice day.

Re: Combining reports dynamically - print blanks the report

Posted: Mon Jan 06, 2014 6:36 am
by midspace
Sorry, I have one additional question with this code.
How do I get the "Edit Page" button to appear?

I've been trying what was suggested in here, but to no avail.
http://forum.stimulsoft.com/viewtopic.php?f=8&t=36868


I already have:
report.PreviewSettings = (int)StiPreviewSettings.All;

And I have tried the following in the Form Load event.
StiOptions.Viewer.Windows.ShowPageDesignButton = true;

Has this feature been removed?

Re: Combining reports dynamically - print blanks the report

Posted: Mon Jan 06, 2014 7:52 am
by Alex K.
Hello,

Please check the last prerelease build and let us know about th result.

Thank you.

Re: Combining reports dynamically - print blanks the report

Posted: Mon Jan 06, 2014 11:28 pm
by midspace
Aleksey wrote:Hello,

Please check the last prerelease build and let us know about th result.

Thank you.
I've just tried the Build Stimulsoft Reports.Ultimate 2013.12.30 [2014.1.1803.0]
I still cannot get the "Edit Page" button to appear.

Re: Combining reports dynamically - print blanks the report

Posted: Wed Jan 08, 2014 7:44 am
by Alex K.
Hello,

We couldn't reproduce this bug.
Please try to checkthat you uses the last prerelease build.
Also please try to remove the settings folder:
c:\Users\[userName]\AppData\Local\Stimulsoft\

Thank you.