Page 1 of 1
How to offsetting the x-axis label in be in the center
Posted: Wed Feb 18, 2009 1:08 pm
by 9527011
I need to adjust the label of the x-axis in a report to be centered as depicted in the picture (Pic 1).
This is what I was able to achieve so far with no luck. (Pic2).
Posted: Wed Feb 18, 2009 2:19 pm
by yeray
Hi Oblicore,
Could you please try this code and see if it works at your end?
Code: Select all
Private Sub Form_Load()
TeeCommander1.ChartLink = TChart1.ChartLink
TChart1.AddSeries scPoint
TChart1.Series(0).FillSampleValues 10
TChart1.Aspect.View3D = False
TChart1.Environment.InternalRepaint
End Sub
Private Sub TChart1_OnAfterDraw()
With TChart1.Axis.Bottom
.Labels.Clear
For i = .Minimum To .Maximum
.Labels.Add i + 0.5, Str$(Round(i))
Next i
End With
End Sub