I have a Composite Chart with a Line and Gantt Chart in seprate Chart Areas as per the attached graphics file
I am trying to achieve X Axis Synchronisation so that the user can compare medication timelines with pathology results to see the effect of the medications
I have an xAxis for each chart area, it is on the same type
For chart area 0
'Define the axis for the chart With axisX .DataType = AxisDataType.Time .TickmarkStyle = AxisTickStyle.DataInterval .Extent = 63 With .Labels .SeriesLabels.Font = New System.Drawing.Font("Lucida Console", 10) .ItemFormat = AxisItemLabelFormat.Custom .ItemFormatString = "<ITEM_LABEL:dd-MMM-yyyy>" .Layout.Padding = 2 .Orientation = TextOrientation.VerticalLeftFacing .Visible = True End With .OrientationType = AxisNumber.X_Axis '.RangeType = AxisRangeType.CustomChart area 1
'Define the axis for the chart With axisXGantt .DataType = AxisDataType.Time .TickmarkStyle = AxisTickStyle.DataInterval .Extent = 64 .Visible = True With .Labels .ItemFormat = AxisItemLabelFormat.ItemLabel .ItemFormat = AxisItemLabelFormat.Custom .ItemFormatString = "<ITEM_LABEL:dd-MMM-yyyy>" .Layout.Padding = 2 .SeriesLabels.Visible = False .Orientation = TextOrientation.VerticalLeftFacing .Visible = True End With .OrientationType = AxisNumber.X_Axis .RangeType = AxisRangeType.Automatic ' Using rulergenre = continuous keeps the date intervals regular and chart x axis smooth .TimeAxisStyle.TimeAxisStyle = RulerGenre.Continuous .TickmarkStyle = AxisTickStyle.Smart
but the X axis do not line up Any help appreciated please
Hi,
The easiest way to solve your requirements, could be if you are using two areas with one and the same X and Y axis. By this way you could synchonize your Scalling and Scrolling.
Please take a look at the attached video file for more details and let me know if you have any questions.
Regards
Here is the video
Have you been able to resolve your issue ? If you still have any concerns or questions I will be glad to help. If you need any additional assistance don’t hesitate to ask.