Hi Jenith,
The platform is winforms :vb.net.
The version is: 28.1.33
No special or other settings.
The code snippet is the snippet used above: ChartStatLines_6068.zip
This is unfortunatly not in the correct language.
for the errors, I just deleted the form building line about the orientation.. This parameter does not seem to exists (anymore).
For the license error, I removed the file with the license key (.licx) from the application. Then it worked.. The greatest question remain (the one that I was trying to solve reading this snippet...). So therefore, the snippet is not so relevant anymore but the only question that remains:
And, how to do this without double values on the X-axis. I have string values, and the same string is present multiple times... The horizontal line must go from the primary Y-axis over the complete chart width.
the X-axis are string labels: 4,5,6,......52,1,2,3,4. These are weeknumbers, But no real numbers ofcourse!!!.. As you see, these values can not be sorted while they must stay in the order of the underlaying table. There is 2 times (Week) 4. (next week, it will be week 5).
So I can not work with min and max value but must be on coordinates or something.
The sorting is off, while the graph is build in the order
EDIT: Maybe I should ask this in another forum post:
While the width of the chartstripline is not easy to control (I can not give ith a width of 0,01) I get big lines if I display something in smaller values. Therefore I want to go back in displaying the data in a line graph (and solving the above by getting all X-vaules from the similar datatable as the displayed columns). I can easiliy draw a nice controlled target line. However, on the drawn target line, I want to put on the line some text. That is easy with a chartstripline but not easy with a normal line.. How to do this? ChatGPT suggest annotations, but I can not find any annotation properties in syncfusion.
Hi Korsmit,
We are currently investigating the details and provided sample. we will provide you with further updates within two business days, by January 27th, 2025.
Thank you for your understanding and cooperation.
Best regards,
Arul Jenith B.
Hi Korsmit,
We are currently investigating the query and preparing the sample in winforms VB.NET with your requirements. we will provide you with further updates within one business days, by January 28th, 2025.
Thank you for your understanding and cooperation.
Best regards,
Arul Jenith B.
Hi Korsmit,
We have prepared a sample in WinForms VB .NET, similar to the one you previously provided. We've modified the double value axis to a category axis using string labels. Please review the attached sample for your reference.
Here is a simple code snippet:
Private Sub InitializeComponent() Dim resources As New System.Resources.ResourceManager(GetType(Form1)) Me.chartControl1 = New ChartControl() Me.SuspendLayout()
Me.chartControl1.Legend.Anchor = AnchorStyles.Top Or AnchorStyles.Right Me.chartControl1.Legend.Location = New Point(450, 172) Me.chartControl1.Legend.Name = "" Me.chartControl1.Legend.Size = New Size(76, 28) Me.chartControl1.Legend.TabIndex = 3 Me.chartControl1.Location = New Point(0, 0) Me.chartControl1.Name = "chartControl1" Me.chartControl1.PrimaryXAxis.Orientation = Orientation.Horizontal Me.chartControl1.PrimaryXAxis.LabelRotate = True Me.chartControl1.PrimaryXAxis.LabelRotateAngle = 45 Me.chartControl1.Text = "Essential Chart"
Me.Name = "Form1" Me.Text = "Sample" AddHandler Me.Load, AddressOf Me.Form1_Load Me.ResumeLayout(False) End Sub
Protected Sub InitializeChartData() Dim random As New Random() Dim weekLabels As String() = {"4", "5", "6", "7", "8", "9", "10", "11", "12", "13", "14", "15", "16", "17", "18", "19", "20", "21", "22", "23", "24", "25", "26", "27", "28", "29", "30", "31", "32", "33", "34", "35", "36", "37", "38", "39", "40", "41", "42", "43", "44", "45", "46", "47", "48", "49", "50", "51", "52", "1", "2", "3", "4"}
For i As Integer = 0 To 1 Dim series As New ChartSeries("Series " & i, ChartSeriesType.Column) For j As Integer = 0 To weekLabels.Length - 1 series.Points.Add(weekLabels(j), New Double() {random.Next(500)}) Next series.Text = series.Name series.Style.DisplayShadow = False Me.chartControl1.Series.Add(series) Next
Me.chartControl1.PrimaryXAxis.DrawGrid = False Me.chartControl1.PrimaryYAxis.DrawGrid = False End Sub
|
An output image is attached for visualization. Should you require further assistance, please feel free to reach out.
Could you please provide the more information for below query that you mentioned. This helps us to provide the better solution.
Query: I can not work with min and max value but must be on coordinates or something.
Thank you for your understanding and continued support.
Regards,
Arul Jenith B.