Page 1 of 1
X-axis labels disappear as control is sized larger
Posted: Wed Feb 02, 2005 9:33 pm
by 8122275
I'm having a problem with the labels on the x-axis disappearing as the size of the TeeChart control gets larger. As the window (and the TeeChart control) is dragged larger, the labels that are showing disappear except for the label at 0. I've got a very simple example with the 20 numbers 0, 0.005, 0.010, ... 0.100. I've played with the ValueFormat property of the Labels, but the only value that I've found that doesn't cause the labels to disappear is "". Besides going to custom labels, is there a way to work around this behavior or will this be changed in a future release?
Thanks.
Posted: Wed Feb 02, 2005 11:12 pm
by Pep
Hi,
have you set a bottom axis increment like :
tChart1.Axes.Bottom.Increment = 0.005;
?
Posted: Fri Feb 04, 2005 2:07 pm
by 8122275
Thanks, that works. Though, I don't understand why I should have to do set the increment. It's somehow able to handle placing the labels initially. When the control gets smaller it knows how to calculate a new increment such that labels don't overlap. Seems like it should apply the same idea when the control gets wider: calculate an increment such that the labels don't overlap, the only difference being that this increment will be smaller than the previous increment.
Anyway, I've got code that works so I'm good for now.
Thanks much!