Page 1 of 1

Grid Visualization of a TeeChart

Posted: Tue Apr 27, 2010 12:08 pm
by 10554269
Hello. I have a problem to represent a chart in a grid;

I have: TeeChart with some TFastLine series -->> TChartDataSet -->> TDataSource -->> Grid (QuantumGrid)

If the series has a different XValues, It´s represented in the grid something like:

Serie1.X______Serie1.Y______Serie2.X_____Serie2.Y
-----------------------------------------------------------
2____________567__________3___________5768
3____________76687________4___________67865
4____________556__________7___________57656
5____________5666
6____________564

and I want to represent it:

Serie1.X______Serie1.Y_______Serie2.X_____Serie2.Y
-----------------------------------------------------------
2____________567___________--___________---
3____________76687_________3___________5768
4____________556___________4___________67865
5____________5666__________--___________--
6____________564___________--___________--
--____________--____________7___________57656

Anyone know how I can do? changing the series? changing the dataset?
Thank you.

Re: Grid Visualization of a TeeChart

Posted: Thu Apr 29, 2010 10:29 am
by narcis
Hi realtracksystems,

The only solution I can think of is adding null values to the series for those points. You have several options to add a null point to a series:

1. Use AddNull.
2. Use AddNullXY
3. Use any Add, AddXY, ... method override setting point color to clNone.
4. Use SetNull method for setting a specific point to null.

You can then choose how to represent null values in your chart as shown in the All Features\Welcome!\Chart Styles\Fast Line\Fast Line TreatNulls example in the new features demo available at TeeChart's program group.

Regarding what's displayed in the grid, does it have any event to manually parse cells text and modify it for null values?

Hope this helps!

Re: Grid Visualization of a TeeChart

Posted: Thu Apr 29, 2010 2:02 pm
by 10554269
Hi Narcis. First, thanks for the reply. I had already thought of that solution. I eliminated it, because this produces effects graphics to represent the series:

Skip Nulls: when I scroll chart, the first value always start drawing at 0.
DontPaint Nulls: no points are linked with each other and the plot seems "broken"
Ignore Nulls: draw all nulls at 0. This produces a different effect.
Dibujo.JPG
Dibujo.JPG (40.81 KiB) Viewed 4148 times

Anyway I appreciate your quick response and I'll keep thinking.

Regards

Re: Grid Visualization of a TeeChart

Posted: Thu Apr 29, 2010 2:23 pm
by narcis
Hi realtracksystems,

You're very welcome.
Skip Nulls: when I scroll chart, the first value always start drawing at 0.
In that case you could use AddNullXY to set the value you want for the null point so that it's not painted at 0. Does this fit your needs?

Re: Grid Visualization of a TeeChart

Posted: Fri Apr 30, 2010 8:00 am
by 10554269
Hi Narcis.

With this I have solved part of the problem. I think the other part depends on the grid component.

A greeting and thanks.