Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
See more: C#
Hello!
I use this code:
            chartStatistic.DataSource = _manager.myPointList;
 
            Series series = new Series("seriesName"); 
         
            series.XValueMember = "Date";
            series.YValueMembers = "Count";
 
            chartStatistic.Series.Add(series);
Every Element of myPointList has a date value and a count value.
Problem:
The date values are not below the bars in the chartcontrol.
Chartcontrol shows 14 bars but only 8 Dates. How can i do this?
 
Regards
Posted 4-Oct-12 7:17am
Edited 4-Oct-12 7:22am
RaisKazi32.8K
v2

1 solution

Rate this: bad
good
Please Sign up or sign in to vote.

Solution 1

            chartStatistic.ChartAreas[0].AxisX.Interval = 1; 
 
This works =)
  Permalink  

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 Sergey Alexandrovich Kryukov 495
1 OriginalGriff 339
2 ChintanShukla 305
3 Richard Deeming 235
4 RyanDev 230
0 Sergey Alexandrovich Kryukov 8,858
1 OriginalGriff 7,451
2 CPallini 2,603
3 Richard MacCutchan 2,095
4 Abhinav S 1,893


Advertise | Privacy | Mobile
Web02 | 2.8.140827.1 | Last Updated 5 Oct 2012
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100