I'm charting a 4 series stacked bar graph.
My problem is that a thin line of color still shows up at the top of the bar graph for the 4th series, even when the value for that bar/series is 0.
This is distracting to my users, as they don't want to see the color in question at all when there is no data for that color.
Waynewil
stacking problem
Hi Wayne,
using the latest build of TeeChart, Build 1.1.1499.42325 this can be solved adding the bars which the value is 0 with Color.Transparent :
using the latest build of TeeChart, Build 1.1.1499.42325 this can be solved adding the bars which the value is 0 with Color.Transparent :
Code: Select all
bar1.Add (10,"");
bar1.Add (0,"",Color.Transparent);
bar1.Add (15,"");
bar1.Add (3,"");
bar1.Add (12,"");
bar2.Add (30,"");
bar2.Add (0,"",Color.Transparent);
bar2.Add (0,"",Color.Transparent);
bar2.Add (10,"");
bar2.Add (34,"");
bar1.MultiBar = Steema.TeeChart.Styles.MultiBars.Stacked;
Pep Jorge
http://support.steema.com
http://support.steema.com
Thanks for the reply, Josep.
However, I still require a little clarification.
I've got four series being fed by a dataset. It is the top series in the stack that seems to have the persistent line. Are you saying that I should add a fifth series with a value of zero and a transparent color, so that the top series still persists - it just can't be seen?
Wayne
However, I still require a little clarification.
I've got four series being fed by a dataset. It is the top series in the stack that seems to have the persistent line. Are you saying that I should add a fifth series with a value of zero and a transparent color, so that the top series still persists - it just can't be seen?
Wayne
Josep,
Actually, this problem is a little more irritating than I previously described.
Through experimenting, I've found that if I have the following situation for a column:
Bar 1 = 20
Bar 2 = 0
Bar 3 = 10
Bar 4 = 0
Thin lines show up for Bar 2 and Bar 4 in their respective colors, which is very distracting to the user. This system being fed by a dataset and graphing automatically, including with appropriate scaling, bar width, etc., I'd really rather not manually make the color transparent per column.
Can you guys simply not fix this to make sure that if a bar has a value of zero, it doesn't show up in a stacked graph?
Wayne
Actually, this problem is a little more irritating than I previously described.
Through experimenting, I've found that if I have the following situation for a column:
Bar 1 = 20
Bar 2 = 0
Bar 3 = 10
Bar 4 = 0
Thin lines show up for Bar 2 and Bar 4 in their respective colors, which is very distracting to the user. This system being fed by a dataset and graphing automatically, including with appropriate scaling, bar width, etc., I'd really rather not manually make the color transparent per column.
Can you guys simply not fix this to make sure that if a bar has a value of zero, it doesn't show up in a stacked graph?
Wayne
Marc,
Thanks for responding. Actually, that solves my problem completely. I was using calculated fields from the dataset anyway, so I just used the IIF function to return a null if the result was zero.
Thanks a million. You had me sweating there for a bit, as I have used your graphing tool since it first came out (in Delphi), so I insisted on using your tool for this project...which would have made me look bad if it didn't work. Now I can look bad for other reasons!
Wayne
Thanks for responding. Actually, that solves my problem completely. I was using calculated fields from the dataset anyway, so I just used the IIF function to return a null if the result was zero.
Thanks a million. You had me sweating there for a bit, as I have used your graphing tool since it first came out (in Delphi), so I insisted on using your tool for this project...which would have made me look bad if it didn't work. Now I can look bad for other reasons!
Wayne