1. 3 areas for drawing chart and they can be zoomed independently.
2. Each chart will be drawn many series on it.
3. X co-ordinate of 2 series can be the same or can be different.
4. The X-range of 3 charts must be the same.
5. All charts must have X-Y grid.
6. Only one chart has Visible Bottom Axis.
PROBLEMS WITH TChart Pro V8.0
I try to make a program that using TChart Pro V8.0 to support all above requirements but there are some problems happen that I can’t support:
1. If only one chart has Visible Bottom Axis, other charts will not have grid.
2. The left axes of TRIGGER chart and ENGSTAT chart (Figure 9) can’t be aligned. The position of axis depends on the length of Axis title (TRIGGER, and ENGSTAT). It can’t be fixed in the same line.
PROBLEMS WITH TChart Pro V8.0
-
- Site Admin
- Posts: 14730
- Joined: Mon Jun 09, 2003 4:00 am
- Location: Banyoles, Catalonia
- Contact:
Hi GIT,
Please find below the answers to your questions:
1. You can make axes not visible like this:
For the labels you can set them to a blank space using the OnGetAxisLabel event:
Private Sub TChart1_OnGetAxisLabel(ByVal Axis As Long, ByVal SeriesIndex As Long, ByVal ValueIndex As Long, LabelText As String)
If Axis = 3 Then 'Bottom axis
LabelText = " "
End If
End Sub
2. Why don't you try using TChart1.Axis.Bottom.Labels.Size. The AxisLabels' Size property is 0 by default. Therefore the space between the Axis and the Chart will be automatically calculated based on the Axis Labels Width and Height. Example [Visual Basic]:
You can set this property both at design or runtime:
(50 pixels separation)
Using this may help you align the charts as axes position depend on labels size too.
Please find below the answers to your questions:
1. You can make axes not visible like this:
Code: Select all
TChart1.Axis.Bottom.AxisPen.Visible = False
TChart1.Axis.Bottom.Ticks.Visible = False
TChart1.Axis.Bottom.MinorTicks.Visible = False
Private Sub TChart1_OnGetAxisLabel(ByVal Axis As Long, ByVal SeriesIndex As Long, ByVal ValueIndex As Long, LabelText As String)
If Axis = 3 Then 'Bottom axis
LabelText = " "
End If
End Sub
2. Why don't you try using TChart1.Axis.Bottom.Labels.Size. The AxisLabels' Size property is 0 by default. Therefore the space between the Axis and the Chart will be automatically calculated based on the Axis Labels Width and Height. Example [Visual Basic]:
You can set this property both at design or runtime:
Code: Select all
TChart1.Axis.Right.Labels.Size = 50
Using this may help you align the charts as axes position depend on labels size too.
Best Regards,
Narcís Calvet / Development & Support Steema Software Avinguda Montilivi 33, 17003 Girona, Catalonia Tel: 34 972 218 797 http://www.steema.com |
Instructions - How to post in this forum |
thanks a lot.
I modified source code as your answer,
and it works in good condition.
thank you a lot!
Best regards.
and it works in good condition.
thank you a lot!
Best regards.