C# MS Chart Control - highlight today's date in Gantt Chart
The title of this开发者_如何学编程 question says it all.
I've got a gantt chart (RangeBar) made using the MS Chart Control, and at present I have some StripLines to highlight weekends and the start of each month, but I need one to appear on today's date only so the user can see where we are at the mo.
Is this possible with this control, or am I fishing for unicorns?
If it's possible, how?
Cheers
Nevermind, figured it out:
StripLine strpToday = new StripLine();
strpToday.IntervalOffset = DateTime.Today.ToOADate();
strpToday.StripWidth = 1;
strpToday.BackColor = Color.ForestGreen;
chtHC.ChartAreas[0].AxisY.StripLines.Add(strpToday);
精彩评论