Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
1815
Composite Chart - Line and Gantt Xaxis Synchronisation
posted

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.Custom
Chart 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

Parents Reply Children
No Data