OutOfMemoryException when printing empty databand

Stimulsoft Ultimate discussion
Post Reply
WalterJKR
Posts: 22
Joined: Tue Mar 18, 2014 6:41 am

OutOfMemoryException when printing empty databand

Post by WalterJKR »

Hello Stimulsoft,

One of our reports stopped working with recent versions 2015.2 and 2015.3 of Stimulsoft Ultimate (WPF & .NET). The attempt to print or preview the report ends with OutOfMemoryException with callstack attached bellow. I managed to find out that the problem is in child databand pasted into panel in master databand, which contains no rows. We updated the report and set Panel1 holding Databand2 condition to "StandardniPrijataObjednavka.RadekSet.TypPolozkyVRadku != TypPolozkyVRadku.Sortiment" which disables printing of the databand when there is no row to print. Everything works and the report is printed/displayed successfuly. I have uploaded both broken and fixed reports (.mrt) as attachment.
(excuse czech language in the code, it's only for technical purpose when looking at the reports)

As I mentioned, the broken report worked in one of the previous versions we had installed. Also, we managed to add condition allowing to print without problems. I report this only for you to find the bug and fix it in the future versions.

Thank you.
JW



OutOfMemoryException callstack:

v System.Collections.Generic.List`1.set_Capacity(Int32 value)
v System.Collections.Generic.List`1.EnsureCapacity(Int32 min)
v System.Collections.Generic.List`1.Add(T item)
v Stimulsoft.Report.Dictionary.StiBusinessObjectHelper.GetBusinessObjectsFromReport(StiBusinessObjectsCollection businessObjects)
v Stimulsoft.Report.Dictionary.StiBusinessObjectHelper.GetBusinessObjectsFromReport(StiBusinessObjectsCollection businessObjects)
v Stimulsoft.Report.Dictionary.StiBusinessObjectHelper.GetBusinessObjectsFromReport(StiReport report)
v Stimulsoft.Report.Dictionary.StiBusinessObjectHelper.GetBusinessObjectFromGuid(StiReport report, String guid)
v Stimulsoft.Report.Components.StiDataBand.get_BusinessObject()
v Stimulsoft.Report.Components.StiDataBand.get_IsEof()
v Stimulsoft.Report.Engine.StiDataBandV2Builder.RenderMaster(StiDataBand masterDataBand)
v Stimulsoft.Report.Components.StiDataBand.RenderMaster()
v Stimulsoft.Report.Engine.StiSubReportsHelper.RenderDataBandsInContainer(StiContainer containerOfDataBands, StiContainer container, Boolean skipStaticBands)
v Stimulsoft.Report.Engine.StiContainerV2Builder.InternalRender(StiComponent masterComp)
v Stimulsoft.Report.Components.StiComponent.InternalRender()
v Stimulsoft.Report.Engine.StiComponentV2Builder.Render(StiComponent masterComp)
v Stimulsoft.Report.Components.StiComponent.Render()
v Stimulsoft.Report.Engine.StiContainerV2Builder.InternalRender(StiComponent masterComp)
v Stimulsoft.Report.Engine.StiBandV2Builder.InternalRender(StiComponent masterComp)
v Stimulsoft.Report.Components.StiComponent.InternalRender()
v Stimulsoft.Report.Engine.StiEngine.InternalRenderBand(StiBand band, Boolean ignorePageBreaks, Boolean allowRenderingEvents, Boolean& isChildsEnabled)
v Stimulsoft.Report.Engine.StiEngine.RenderBand(StiBand band, Boolean ignorePageBreaks, Boolean allowRenderingEvents)
v Stimulsoft.Report.Engine.StiDataBandV2Builder.RenderBand(StiDataBand masterDataBand, StiBand band, Boolean ignorePageBreaks, Boolean allowRenderingEvents)
v Stimulsoft.Report.Engine.StiDataBandV2Builder.RenderMaster(StiDataBand masterDataBand)
v Stimulsoft.Report.Components.StiDataBand.RenderMaster()
v Stimulsoft.Report.Engine.StiDataBandV2Builder.RenderDetailDataBands(StiDataBand masterDataBand)
v Stimulsoft.Report.Engine.StiDataBandV2Builder.RenderMaster(StiDataBand masterDataBand)
v Stimulsoft.Report.Components.StiDataBand.RenderMaster()
v Stimulsoft.Report.Engine.StiPageHelper.RenderPage(StiPage page)
v Stimulsoft.Report.Engine.StiRenderProviderV2.RenderReport(StiReport report, StiReport masterReport, StiRenderState state)
v Stimulsoft.Report.Engine.StiRenderProviderV2.Render(StiReport report, StiRenderState state)
v Stimulsoft.Report.Engine.StiReportV2Builder.RenderSingleReport(StiReport masterReport, StiRenderState renderState)
v Stimulsoft.Report.StiReport.RenderReport(StiRenderState renderState)
v Stimulsoft.Report.StiReport.Render(StiRenderState renderState, StiGuiMode guiMode)
v Stimulsoft.Report.StiReport.RenderWithWpf()
Attachments
reports.zip
(55.74 KiB) Downloaded 245 times
Ivan
Posts: 960
Joined: Thu Aug 10, 2006 1:37 am

Re: OutOfMemoryException when printing empty databand

Post by Ivan »

Hello,

We couldn't reproduce this issue.
Can you please send us a simple test project, which reproduce the issue, for analysis?

Thank you.
WalterJKR
Posts: 22
Joined: Tue Mar 18, 2014 6:41 am

Re: OutOfMemoryException when printing empty databand

Post by WalterJKR »

It will take some time but I'll try.
Alex K.
Posts: 6488
Joined: Thu Jul 29, 2010 2:37 am

Re: OutOfMemoryException when printing empty databand

Post by Alex K. »

Hello,

Thank you. We will wait.
Post Reply