Profile Picture

show Y axis labels shows not the range of labels specified

Posted By Willie-Jan Bons 14 Years Ago

show Y axis labels shows not the range of labels specified

Author
Message
Willie-Jan Bons
questionmark Posted 14 Years Ago
View Quick Profile
Forum Newbie

Forum Newbie (6 reputation)Forum Newbie (6 reputation)Forum Newbie (6 reputation)Forum Newbie (6 reputation)Forum Newbie (6 reputation)Forum Newbie (6 reputation)Forum Newbie (6 reputation)Forum Newbie (6 reputation)Forum Newbie (6 reputation)

Group: Forum Members
Last Active: 14 Years Ago
Posts: 6, Visits: 1

I want to show my own labels on the Y-axis.
However it does some strange thing and shows 2 labels in stead of all (see jpg).
What am i doing wrong here?

 

Dim Chart As NChart

Chart = NDSChart.Charts.Item(0)

NDSChart.Legends.Clear()

NDSChart.Settings.RenderDevice = Nevron.GraphicsCore.RenderDevice.GDI

Chart.Projection.ViewerRotation = 0

Dim Ax As NAxis = Nothing

Ax = Chart.Axis(StandardAxis.PrimaryY)

Chart.Axis(Nevron.Chart.StandardAxis.PrimaryX).Visible = True

Chart.Axis(Nevron.Chart.StandardAxis.PrimaryY).Visible = True

Dim NumScaley As New NOrdinalScaleConfigurator

NumScaley.AutoLabels = False

NumScaley.Labels.Clear()

For i As Integer = 1 To 17

NumScaley.Labels.Add(i.ToString)

Next

NumScaley.RoundToTickMax = False

NumScaley.RoundToTickMin = False

Chart.Axis(StandardAxis.PrimaryY).ScaleConfigurator = NumScaley

Chart.Axis(StandardAxis.PrimaryY).InvalidateScale()

Dim b1 As NLineSeries = Chart.Series.Add(SeriesType.Line)

b1.MarkerStyle.Visible = True

b1.DataLabelStyle.Visible = False

b1.MarkerStyle.PointShape = PointShape.Cross

Chart.Axis(StandardAxis.PrimaryX).ScaleConfigurator = New NOrdinalScaleConfigurator

If Not IsNothing(Ax) Then

Dim scalex As NStandardScaleConfigurator = Ax.ScaleConfigurator

scalex.MajorGridStyle.LineStyle.Pattern = Nevron.GraphicsCore.LinePattern.Solid

scalex.MajorGridStyle.LineStyle.Width = New Nevron.GraphicsCore.NLength(1)

scalex.MajorGridStyle.LineStyle.Factor = 1

scalex.LabelStyle.Angle = New NScaleLabelAngle(ScaleLabelAngleMode.UseCustomAngle, 0)

End If

Dim P As New NDataPoint(2.84)

b1.AddDataPoint(P)

P = New NDataPoint(2.97)

b1.AddDataPoint(P)

P = New NDataPoint(3.52)

b1.AddDataPoint(P)

P = New NDataPoint(3.4)

b1.AddDataPoint(P)

P = New NDataPoint(4.07)

b1.AddDataPoint(P)

P = New NDataPoint(3.1)

b1.AddDataPoint(P)

P = New NDataPoint(3.23)

b1.AddDataPoint(P)

P = New NDataPoint(2.94)

b1.AddDataPoint(P)

P = New NDataPoint(3.1)

b1.AddDataPoint(P)

P = New NDataPoint(3.23)

b1.AddDataPoint(P)

P = New NDataPoint(2.94)

b1.AddDataPoint(P)

P = New NDataPoint(3.1)

b1.AddDataPoint(P)

P = New NDataPoint(3.22)

b1.AddDataPoint(P)

P = New NDataPoint(3.18)

b1.AddDataPoint(P)

P = New NDataPoint(3.02)

b1.AddDataPoint(P)

P = New NDataPoint(3.62)

b1.AddDataPoint(P)

P = New NDataPoint(3.27)

b1.AddDataPoint(P)

NDSChart.Visible = True

NDSChart.Refresh()



Attachments
nevron.jpg (43 views, 62.00 KB)



Similar Topics


Reading This Topic