Page 1 of 1

Need help with custom axis

Posted: Fri Dec 30, 2005 2:58 pm
by 9527833
Hello,

This is probably not that difficult, but I can't figure out how to do it... I basically need this:

Image



The area on the chart that represents an x value of 1 normally (on this type of chart) would be any where between the y-axis and the dark vertical line shown. The same with the rest of the numbers.

However, I can plot any of the x-values directly above the actual number if need be.

What is really needed is for the x-axis to look like above with the vertical (darker) lines situated like shown (I don't want darker lines on the actual numbers).


I really hope this makes sense as it is kind of hard to describe.

Thanks!

Andrew



What I really need is to be able to create this axis

Posted: Mon Jan 02, 2006 10:32 am
by Pep
Hi Andrew,

this axis style can be done using the following code :

Code: Select all

Private Sub Form_Load()
With TChart1
    .Aspect.View3D = False
    .AddSeries scPoint
    .Series(0).FillSampleValues (10)
    With .Axis.Bottom
        .Ticks.Visible = False
        .MinorTickCount = 1
        .MinorTickLength = 2
        .MinorTicks.Width = 2
        .MinorGrid.Visible = True
        .GridPen.Visible = False
        .MinimumOffset = 20
        .MaximumOffset = 20
    End With
    .Axis.Left.GridPen.Style = psSolid
End With
End Sub

Posted: Tue Jan 03, 2006 2:48 pm
by 9527833
It didn't work for my chart, but I will look into it furthur to see why. Thanks.