Jump to content
Software FX Community

Performance Problem


pearsonj

Recommended Posts

Hi,

I have an app with a small amount of data points on a chart (~200 points).  I have a button to reload the chart with random numbers.  On my development machine, the data resets super fast (I percieve no time).  When I run the app on non development machines, the same button press takes over 1 second to redraw.  Do you have any idea why this might happen?

thanks, Jake

Link to comment
Share on other sites

http://www.maad.com/uploads/images/196/ChartPerformance.zip

Hi,

You can download a sample from the above link. I put a randomize button that will fill a chart with 100 random numbers.  On my computer, the action seems instant.  On my test computer it takes at least 2 seconds (I have tried it on Vista and XP).  Just to make sure I didn't have a really slow test computer, I made a similar function to add 100 items to a list box.  The performance seems to be about the same on both computers (basically instant).  I have ChartFX and the extensions library on my computer (I'm not using the extensions).  I also included the output from ProcMon when I run the chart version of the randomize button.  It is called Logfile.csv and is in the Visual Studio project.  There are a large number of registry hits when I try to load up the chart that I don't have with the listbox.

thanks, Jake

Link to comment
Share on other sites

Like in your computer, this code runs instantly on mine.

Also, I don;t see anything in the code that may be causing this poor performance.

One thing that I see that is not normal is that your project doesn't have a .licx file. Licx files are automatically created by VS when you drop a control in the form and direct the compiler to include the license resources into the executable.

When the program runs the license is retrieve from within the executable, this is what allows for deployment of application containing licensed controls and running them in computers in which there is no development license for them. If, at run-time, the EXE does not contain the license, Chart FX will fallback to looking for a development license in the registry. This may explain the registry access although it does not explain the poor performance.

The license, however, is checked when the first control is created so I should not affect the performance of the "Randomize Button", unless your license is a local license (Developer Studio) which can not be deployed or a trial license which may check to see if the license has expired.

Try adding the license.licx to your project (as an embedded resource). The license.licx is simply a text file containing the following:

 ChartFX.WinForms.Chart, ChartFX.WinForms, Version=<your version here>, Culture=neutral, PublicKeyToken=a1878e2052c08dce

If you create a new project and drop a Chart Visual Studio should create one for you.

Other than that I can't think of anything else that could be causing this poor performance.

Link to comment
Share on other sites

  • 2 weeks later...

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...