A short explanation what I do: I have a chart, where i show a Label for the Min and Max Value. If the appropriate Extrema are on the right side of the chart, the Label is aligned left. (If it's left, then the label is aligned right) The Y-Axis has timestamsp, so I calculate the Datediff, to align the Label.
minPos = (minTupel.Value.Time - srtTupel.Value.Time)
> (endTupel.Value.Time - minTupel.Value.Time)
? "Left" : "Right";
maxPos = (maxTupel.Value.Time - srtTupel.Value.Time)
> (endTupel.Value.Time - maxTupel.Value.Time)
? "Left" : "Right";
But the chart ignores the weekends, because there are no values. If I calculate the difference between Thursday and Monday, the result is 4 Days, but the chart only shows 2. Therefore the label is aligned right, when it should be left. Is there any option to get the Datediff without the Weekends?