Out of Memory Exception

Stimulsoft Ultimate discussion
shan
Posts: 51
Joined: Mon Nov 05, 2012 10:16 am

Out of Memory Exception

Post by shan »

Dear Friends,
I have designed the stimulsoft report with more than 30 image components, when i rendered some times it flows data and image correctly, but some times it shows out of memory exception error.

Also note that i am binding the image URL from the database by using variable in stimulsoft as per below mentioned coding in GetImageDataEvent.

if(System.IO.File.Exists(AttachmentPath)==true)
{
Image2.Enabled=true;
e.Value = Image.FromFile(string.Format(AttachmentPath));
}
else
{
Image2.Enabled=false;
}

Can any one describe about this error?
Alex K.
Posts: 6488
Joined: Thu Jul 29, 2010 2:37 am

Re: Out of Memory Exception

Post by Alex K. »

Hello,

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

Thank you.
shan
Posts: 51
Joined: Mon Nov 05, 2012 10:16 am

Re: Out of Memory Exception

Post by shan »

Hi,

I am using the Stimulsoft Ultimate Version 2012.1. Whether i want to use next release of this version.

Thank You.
Ivan
Posts: 960
Joined: Thu Aug 10, 2006 1:37 am

Re: Out of Memory Exception

Post by Ivan »

Hello,

Please try to set the following static option:

Code: Select all

StiOption.Engine.ImageCache.Enabled = true;
If the issue is still present, please send us a sample report with data or a simple test project, which reproduce the issue.

Thank you.
User avatar
tpontow
Posts: 206
Joined: Thu Sep 06, 2012 8:46 am
Location: Bonn, Germany

Re: Out of Memory Exception

Post by tpontow »

Off Topic: By the way, you can write your if-clause like that:

Code: Select all

using System.IO;
...
if(File.Exists(AttachmentPath)){...}
Thorsten Pontow

It is easier to write an incorrect program than to understand a correct one. (Alan J. Perlis, Epigrams in programming No. 7)
HighAley
Posts: 8431
Joined: Wed Jun 08, 2011 7:40 am
Location: Stimulsoft Office

Re: Out of Memory Exception

Post by HighAley »

Hello.

Yes, you could use this code.
Do you have any difficulties with it?

Thank you.
shan
Posts: 51
Joined: Mon Nov 05, 2012 10:16 am

Re: Out of Memory Exception

Post by shan »

Hi,
i have tried all the options but still the issue is present.

Kindly note that the issue not coming always. If i run without images there is nothing problem it runs smoothly all the times.

But if i run with image path then only problem persists. Also note that the issue is coming randomly.

The report will run upto 355 pages. If i run for first time it runs all the pages when i run again it shows error out of memory in the middle of 150 pages approx.
But if i run with a filter after every full pages render then it will render all the pages.

Did anyone know how to dispose the existing connection when we starting render process newly or any other to idea to overcome this issue.

Thank you.
HighAley
Posts: 8431
Joined: Wed Jun 08, 2011 7:40 am
Location: Stimulsoft Office

Re: Out of Memory Exception

Post by HighAley »

Hello, shan.

Did you try our latest prerelease build?
It was already published 2012.2 release and several prerelease builds.

Thank you.
shan
Posts: 51
Joined: Mon Nov 05, 2012 10:16 am

Re: Out of Memory Exception

Post by shan »

Hi
I have tried the latest release 2012.2 also, but the same error persists.

Kindly note that the error is not coming always.

Thank you.
HighAley
Posts: 8431
Joined: Wed Jun 08, 2011 7:40 am
Location: Stimulsoft Office

Re: Out of Memory Exception

Post by HighAley »

Hello.

Please send us your report template with data to reproduce the issue.

Thank you.
Post Reply