How do I draw a line that starts today say at 9 pm and goes thru to tomorrow 8 am?
My draw line statement is as follows:
DrawLine(HighLine.ToString(), false, StartTime, HH, EndTime, HH, Color.Green, DashStyle.Solid, 2);
Where StartTime & EndTime are:
StartTime = new DateTime(Time[0].Year, Time[0].Month, Time[0].Day, 21, 00, 0);
EndTime = new DateTime(Time[0].Year, Time[0].Month, Time[0].Day, 8, 00, 0);
It works just fine when I want it to draw lines from say 8 am to 11 am. But from the night session thru the day session, it draws the line from 8 am of the current day to 9 pm of the current day as oppose to from 9 pm of current day to 8 am of the following day.
All help is greatly appreciated.
Comment