Swaping values and series in bar-chart

TeeChart VCL for Borland/CodeGear/Embarcadero RAD Studio, Delphi and C++ Builder.
Normand Peladeau
Newbie
Newbie
Posts: 30
Joined: Tue Dec 28, 2004 5:00 am
Contact:

Swaping values and series in bar-chart

Post by Normand Peladeau » Thu Sep 22, 2005 8:28 pm

Is there an easy way to swap values and series in a bar-chart. For example, if you have 3 series of 10 data point each, change this so that you get 10 series of 3 data point each.

I am doing this manually by adding additional series and then removing old series, but this solution causes some run time errors when done repeatedly.

Before looking at the details of my code, I thought I would check first to see whether a method to do this already exists. (if not, consider this a suggestion for a new feature).

Narcís
Site Admin
Site Admin
Posts: 14730
Joined: Mon Jun 09, 2003 4:00 am
Location: Banyoles, Catalonia
Contact:

Post by Narcís » Fri Sep 23, 2005 10:38 am

Hi Normand,

I'm afraid there's no method for doing that.

Could you please send us the code you are using so that we can reproduce the problem here?

You can post your files at [url]news://www.steema.net/steema.public.attachments[/url] newsgroup

Could you also let as know of real situations when this feature should be used so that it can be considered as a feature request?
Best Regards,
Narcís Calvet / Development & Support
Steema Software
Avinguda Montilivi 33, 17003 Girona, Catalonia
Tel: 34 972 218 797
http://www.steema.com
Image Image Image Image Image Image
Instructions - How to post in this forum

Normand Peladeau
Newbie
Newbie
Posts: 30
Joined: Tue Dec 28, 2004 5:00 am
Contact:

Swapping values

Post by Normand Peladeau » Sun Sep 25, 2005 12:53 pm

I will try to create a sample application and give you and example of how it can be used.

Normand

Normand Peladeau
Newbie
Newbie
Posts: 30
Joined: Tue Dec 28, 2004 5:00 am
Contact:

Swapping values

Post by Normand Peladeau » Sun Sep 25, 2005 12:54 pm

I will try to create a sample application and give you and example of how it can be used.

Normand

Normand Peladeau
Newbie
Newbie
Posts: 30
Joined: Tue Dec 28, 2004 5:00 am
Contact:

Post by Normand Peladeau » Tue Sep 27, 2005 6:52 pm

I sent the SwapSeries.zip file with a simple project that replicated the problem. If you swap series repeatedly, quitting the program will produce an access violation. Obviously, there are a few things I didn't understood.

As for possible applications, then you will see that the example I showed you, one may prefer to compare two profiles of frequencies, or concentrate on specific comparisons. Swapping allows one to easily switch from one view to another.

Normand


narcis wrote:Hi Normand,

I'm afraid there's no method for doing that.

Could you please send us the code you are using so that we can reproduce the problem here?

You can post your files at [url]news://www.steema.net/steema.public.attachments[/url] newsgroup

Could you also let as know of real situations when this feature should be used so that it can be considered as a feature request?

Narcís
Site Admin
Site Admin
Posts: 14730
Joined: Mon Jun 09, 2003 4:00 am
Location: Banyoles, Catalonia
Contact:

Post by Narcís » Wed Sep 28, 2005 8:51 am

Hi Normand,

Thanks for the example.

I haven't been able to arise the AV you reported. I swapped series for over one hundred times and closing the app. without getting it. Should I proceed in any specific way?

BTW: Which are the things you don't understand? And which TeeChart version are you using? Please notice that latest version availble is v7.04.
Best Regards,
Narcís Calvet / Development & Support
Steema Software
Avinguda Montilivi 33, 17003 Girona, Catalonia
Tel: 34 972 218 797
http://www.steema.com
Image Image Image Image Image Image
Instructions - How to post in this forum

Normand Peladeau
Newbie
Newbie
Posts: 30
Joined: Tue Dec 28, 2004 5:00 am
Contact:

Post by Normand Peladeau » Wed Sep 28, 2005 12:31 pm

Hum! I get an AV after only a couple of swapping. I am using TeeChart 7.02 as well as the first release of Delphi 7. I will upgrade to version 7.04 and if needed, upgrade also Delphi 7.

I will get back to you on this later today.

Narcís
Site Admin
Site Admin
Posts: 14730
Joined: Mon Jun 09, 2003 4:00 am
Location: Banyoles, Catalonia
Contact:

Post by Narcís » Wed Sep 28, 2005 12:37 pm

Hi Normand,

It would be better if you also install Delphi 7 upgrade.
Best Regards,
Narcís Calvet / Development & Support
Steema Software
Avinguda Montilivi 33, 17003 Girona, Catalonia
Tel: 34 972 218 797
http://www.steema.com
Image Image Image Image Image Image
Instructions - How to post in this forum

Narcís
Site Admin
Site Admin
Posts: 14730
Joined: Mon Jun 09, 2003 4:00 am
Location: Banyoles, Catalonia
Contact:

Post by Narcís » Wed Sep 28, 2005 1:02 pm

Hi Normand,

I forgot to tell you that CrossTab charts support swap feature as you can see in the features demo example (All Features\Welcome\Database Charts\CrossTab Charts). You'll find the features demo at the TeeChart program group.
Best Regards,
Narcís Calvet / Development & Support
Steema Software
Avinguda Montilivi 33, 17003 Girona, Catalonia
Tel: 34 972 218 797
http://www.steema.com
Image Image Image Image Image Image
Instructions - How to post in this forum

Normand Peladeau
Newbie
Newbie
Posts: 30
Joined: Tue Dec 28, 2004 5:00 am
Contact:

Post by Normand Peladeau » Wed Sep 28, 2005 4:03 pm

I updated both TeeChart Pro and Delphi to latest version, and I still get this error message:

Exception EAccessViolation in Module MyChart.exe at FFF3F000.
Access Violation at address FFF40000. Read of address FFF4000.

Any idea what may be wrong?

Narcís
Site Admin
Site Admin
Posts: 14730
Joined: Mon Jun 09, 2003 4:00 am
Location: Banyoles, Catalonia
Contact:

Post by Narcís » Thu Sep 29, 2005 8:51 am

Hi Normand,

It's very difficult to guess without being able to reproduce it. I've tested it again without getting the AV. Do you know of any specific proceeding way we should follow to reproduce the problem here?

BTW: On which environment are you running the application? I'm using Delphi 7 Enterprise (Build 8.1) on a Pentium IV 3,2 MHz machine with 1GB RAM, nVidia GeForce FX 5700 256 MB graphic card and Windows 2003 Server Enterprise + SP1 on it.
Best Regards,
Narcís Calvet / Development & Support
Steema Software
Avinguda Montilivi 33, 17003 Girona, Catalonia
Tel: 34 972 218 797
http://www.steema.com
Image Image Image Image Image Image
Instructions - How to post in this forum

Normand Peladeau
Newbie
Newbie
Posts: 30
Joined: Tue Dec 28, 2004 5:00 am
Contact:

Post by Normand Peladeau » Thu Sep 29, 2005 11:02 pm

Ok! I have Delphi 7 professional (build 8.1), a Pentium IV, 3,0 Mhz, with 1.25 Gig RAM, nVidia GeoForce FX 5200 (Windows XP with SP1).

I will upload the ZIP file again, but this time I will include the EXE file. Running it outside the IDE and swaping a few times is enough to create this error. If you can't replicate the problem, my computer is at fault, but if you can, then the source of the problem is in the compiler. I don't want to reinstall from scratch, but I can try to disable as much third party components as I can.

Normand

Narcís
Site Admin
Site Admin
Posts: 14730
Joined: Mon Jun 09, 2003 4:00 am
Location: Banyoles, Catalonia
Contact:

Post by Narcís » Fri Sep 30, 2005 7:45 am

Hi Normand,

Thanks for posting again your project. Running your .exe I didn't get the error you reported, however when closing the application I get:

Error 1:
---------------------------
Normand mychart: Normand MyChart.exe - Application Error
---------------------------
The instruction at "0xfff40000" referenced memory at "0xfff40000". The memory could not be "read".


Click on OK to terminate the program
Click on CANCEL to debug the program
---------------------------
OK Cancel
---------------------------


Error 2:
---------------------------
Application Error
---------------------------
Exception EAccessViolation in module Normand MyChart.exe at FFF3F000.

Access violation at address FFF40000. Read of address FFF40000.


---------------------------
OK
---------------------------


If I compile the application on my machine I don't get those errors. I've posted the .exe I've created at the newsgroups so that you can test it on your machine and check if it works fine for you or do you get the error you reported.
Best Regards,
Narcís Calvet / Development & Support
Steema Software
Avinguda Montilivi 33, 17003 Girona, Catalonia
Tel: 34 972 218 797
http://www.steema.com
Image Image Image Image Image Image
Instructions - How to post in this forum

Normand Peladeau
Newbie
Newbie
Posts: 30
Joined: Tue Dec 28, 2004 5:00 am
Contact:

Post by Normand Peladeau » Fri Sep 30, 2005 9:03 pm

Things are getting quite strange. I installed on a new computer Delphi 7 from the installation CD and then the upgrade for build 8.1.

I then installed TeeChart Pro 7.0.

I compile the MyChart project and still get the same error message as I get on my other computer.

Any idea what may be going wrong?

Narcís
Site Admin
Site Admin
Posts: 14730
Joined: Mon Jun 09, 2003 4:00 am
Location: Banyoles, Catalonia
Contact:

Post by Narcís » Mon Oct 03, 2005 7:24 am

Hi Normand,

Did you test the .exe I posted?
Best Regards,
Narcís Calvet / Development & Support
Steema Software
Avinguda Montilivi 33, 17003 Girona, Catalonia
Tel: 34 972 218 797
http://www.steema.com
Image Image Image Image Image Image
Instructions - How to post in this forum

Post Reply