Page 1 of 2

Out of system resources error using TeeChart in ASP page

Posted: Mon Oct 18, 2004 7:04 pm
by 9078510
Hi,

I've put together a small sample application for you to use in re-creating this error. There are two ASP pages. The first page contains a single button used to open a seperate window containing a chart, created by the second ASP page. After opening 2 or 3 charts (by clicking the chart button 2 or 3 times), and attempting to cascade the windows, one or more "Out of system resources" error doalog boxes appear. Sometimes we get the error after simply opening the charts and not attempting the cascade.

In the second ASP page, the one that creates and displays the chart, there is a subroutine called "positionPageElements" which is run everytime the page resizes and also on page load. In this subroutine are two lines which dynamically set the height and width of the chart object. Commenting out these two lines appears to stop the "Out of system resources" error from appearing.

Since we need the capability of dynamically resizing the chart with the window, we'd like to know if this is a bug or if perhaps we're doing something wrong in the process of resizing the chart object.

Also, the sample uses the evaluation version of TeeChart7ActiveX, however, we've experienced the problem with TeeChart6ActiveX first, and tried the eval to see if it was fixed.

Thanks in advance for your assistance.
Tracey.

Posted: Wed Oct 20, 2004 8:08 am
by Chris
Hi Tracey,
The first page contains a single button used to open a seperate window containing a chart, created by the second ASP page.
When I click on this button I get the following error:

Code: Select all

Error received while attempting to connect to database.
Record the following for debugging:
Connection to database
Query String: numevents=1&eventids=76;D0000000;0;611&footprint=false
Error description: [Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified
Any pending Trends will NOT be displayed.
Would you mind posting a modified example that I can run "as-is" here?

Many thanks!

Posted: Wed Oct 20, 2004 5:05 pm
by 9078510
Hi Chris,

Sorry about that, I neglected to mention it needed a DSN setup to the database.
Would you mind posting a modified example that I can run "as-is" here?


I've uploaded another version of the application which usees a DSN-less connection. Please let me know if you have any further issues getting the sample to run.

Thanks for your time,
Tracey.

Posted: Thu Oct 21, 2004 9:07 am
by Chris
Hi Tracey,
I've uploaded another version of the application which usees a DSN-less connection. Please let me know if you have any further issues getting the sample to run.
Many thanks. I've now been able to run and reproduce the issue.

On my machine, the "IE: Out of System Resources" error message occurs only when using TaskBar -> Undo Cascade.

The curious thing here is that even having commented out all references to TChart Width and Height in showChart.asp I still get this error message.

On the other hand, if I use a very simple showChart.asp such as this one:

Code: Select all

<HTML>
<BODY>
<object classid="clsid:FAB9B41C-87D6-474D-AB7E-F07D78F2422E" id="TChart"  codebase="downloads/Teechart7.cab#version=7,0,0,2" type="application/x-oleobject" 
    width="100%" height="75%" align="center" hspace="0" vspace="0">
  </object>
</BODY>
</HTML>
I can open several windows and use TaskBar -> Cascade Windows and TaskBar -> Undo Cascade with seeing an error message.

This leads me to believe that the problem is related to how the TChart object is being coded in your version of showChart.asp. I recommend that you strip your code down and rebuild it piece by piece until you find from where the problem is originating.

Posted: Thu Oct 21, 2004 5:52 pm
by 9078510
Hi Chris,

I used the example you gave here:
On the other hand, if I use a very simple showChart.asp such as this one:

Code: Select all

<HTML>
<BODY>
<object classid="clsid:FAB9B41C-87D6-474D-AB7E-F07D78F2422E" id="TChart"  codebase="downloads/Teechart7.cab#version=7,0,0,2" type="application/x-oleobject" 
    width="100%" height="75%" align="center" hspace="0" vspace="0">
  </object>
</BODY>
</HTML>
and I was still able to get the "Out of system resources" error by doing the following:

Open TEN chart windows
Cascade windows
Undo cascade
Got the error, just like when using my original charts, just had to use more windows.

Look forward to your reply, Thanks!
Tracey.

Posted: Fri Oct 22, 2004 7:17 am
by Chris
Hi Tracey,
Open TEN chart windows
Cascade windows
Undo cascade
Got the error, just like when using my original charts, just had to use more windows.
I'm afraid I can't reproduce this here. I opened TWENTY chart windows and cascaded and un-cascaded them without receiving an error message.

My machine:
Pentium 4 1.7 MHz, 512MB RAM

Environment:
Windows 2003 Advanced Server (+ all updates)
Internet Explorer v6.0.3790.0 (+ all updates)
TeeChart Pro ActiveX Control v7.0.0.2

Posted: Fri Oct 22, 2004 4:11 pm
by 9078510
Hi Chris,

My Machine:
Also Pentium 4 1.7MHz, 512MB RAM

Environment:
Windows XP 2002 Pro (+ all updates NOT INCLUDING SP2)
Internet Explorer v6.0.2800.1106 (+ all updates NOT INCLUDING SP2)
TeeChart Pro ActiveX Control v7.0.0.2

I found this morning that after a reboot, I had to open 20 windows, cascade them, switch back and forth between them, then tile them horizontally before I got the out of system resources error. Perhaps on your system it takes a little more playing around with the windows and/or even more windows to produce the error. It could also be that Windows XP plays some role in this.

Please let me know if any of this information helps you to recreate the error.

Thanks again for your time,
Tracey.

Posted: Wed Oct 27, 2004 8:33 am
by Pep
Hi Tracey,

you're correct, I'm able to reproduce the problem here. It seems only happens on WinXP system. I've added as a bug on our defect list to be reviewed for the next maintenance releases.
Thanks for the report.

Posted: Wed Oct 27, 2004 5:53 pm
by 9078510
Hi Chris,

Thanks for all your time and effort, I'm glad I wasn't just imagining things.

Can you tell me an approximate time frame when we might expect the next maintenance release? The charting capabilities provided are critical to the release of our application so we're under a lot of pressure to get this fixed or at least implement a work around as soon as possible. We're currently trying to release our application by Nov. 15th and this is the only issue we have to address. We'd appreciate any information you can give us regarding possible work-a-rounds or general time frames for when we might see this fixed. We're also curious to know how critical this bug is to Steema, as we would expect it to be a fairly significant issue, as it is for us.

Thanks in advance for any information you can provide us,
Tracey.

Posted: Thu Oct 28, 2004 2:33 pm
by Pep
Hi,
Can you tell me an approximate time frame when we might expect the next maintenance release?
Most likely will be ready in 2-3 weeks. But I cannot tell for sure that this problem will be fixed. We'll do all the efforts so it can be fixed.
address. We'd appreciate any information you can give us regarding possible work-a-rounds or general time frames for when we might see this fixed.
Ok, if I find a workaround I'll let you know.
We're also curious to know how critical this bug is to Steema, as we would expect it to be a fairly significant issue, as it is for us.
Certanly you're the first customer which advise about this problem, this means that this feature is not much used but for us all the bugs are important so will review it and will try to find a solution.

Posted: Thu Oct 28, 2004 3:30 pm
by 9078510
Thanks for all your effort and your help in this situation. We'll look forward to the updates as they are available.

Tracey.

Posted: Wed Nov 24, 2004 4:22 am
by 5886766
I've seen this with TChart v5 and v7 as well. I had a live chart which dynamically added data to the chart every 2 seconds from XML data provided by a separate ASP page using the XMLHTTP object. Whenever the user creates a new instance of the browser using the File\New command, the system will soon issue the "Out of System Resources" error and reissue the error every time the page attempts to add data to the chart. The error is accelerated if you resize the browser window.

I had assumed it was either due to the creation of the chart, which uses a stored binary chart template, or that the ASP pages shared the same object name and session identifier. However, I wasn't able to confirm either case.

I could provide a small sample if this would help.

Best regards,
Ryan Van Slooten

Posted: Wed Nov 24, 2004 8:39 am
by Pep
Hi Ryan,

does this happens only under WinXP system ?
Yes please, send me an example to the steema.public.attachments newsgroup or directly to me at pep@steema.com

Posted: Mon Nov 29, 2004 11:14 pm
by 5886766
Sorry for the delay. I will post a sample real soon. I have been extremely occupied by my current project.

The error "Out of System Resources" happens on all operating systems that I have tested, not just XP. I have tried it on Win2k, WinXP, and Win2k3 Server. The key to the problem that I have seen is that the browser is created by File/New or CTRL+N. If you resize the browser after you have created a new browser, the system issues the error.

Best Regards,
Ryan Van Slooten

Posted: Wed Dec 15, 2004 6:44 am
by Marc
Hello,

Thanks for all the information. I think there is more than one issue here.

1. Resource issue when connecting to file based (mdb) datasources (This issue may not be relevant here but I'll list it just in case as I saw .mdb mentioned in an early post).
2. Resource issue when resizing TeeChart in a browser page during cascade/un-cascade operations whilst having open several/many such pages.

Description

1. File based (mdb) datasources
High resource utilisation has proved to be an issue when connecting to file based (mdb) datasources. Previous tests have shown that the same or greater load when applied to an integrated dataserver (eg. MS's SQL Server) does not suffer from similar resource limitations. We recommend the use of that type of database for applications where multiple access/high load to a database is expected.

2. Resizing TeeChart during cascade/un-cascade operations
We can reproduce this issue. The problem occurs as a TeeChart internal bitmap is being copied and requesting a windows handle during a TeeChart resize operation in a child Internet Explorer window (here during the cascade/un-cascade tests). In tests to date the problem seems to be limited to IE windows opened, as Ryan observed, as child windows (ie. Ctrl-N from an existing Window). In independently opened IE browsers and in Windows Form-based apps the problem doesn't appear to occur. The problem occurs at a low Windows level that makes it difficult for us to resolve the problem in TeeChart, not at least without further investigating alternative techniques to achieve the required result. If the Chart isn't resized the problem shouldn't occur and that has proved to be the case in tests here to now - feedback on this would be useful. To avoid resize Charts can be fixed size instead of percentage sized.

eg.
<width="400" height="300">
instead of
<width="100%" height="75%">

For regular TeeChart browser applications, where the need to load and resize multiple child browser windows at a time is not necessary, the continued use of % sizing shouldn't be a problem.

Conclusions

1. (mdb files) The issue is long-standing and related to resource use managed outside of TeeChart. The recommended solution remains the use of a server-based database server.

2. (internal bitmaps) We are further investigating a fix to this issue that we feel is related to an IE resource management deficiency. For the moment we recommend the workaround described above.

I hope that may be of help.
Regards,
Marc Meumann