Frequently Asked Component Specific Questions
Options |
Display all FAQ items |
Displaying items 1 to 1 of 1, page 1 of 1
<< previous next >>
TMS FNC UI Pack
How to configure TTMSFNCPlanner with a custom time line
How to configure TTMSFNCPlanner with a custom time line
There are 2 ways you can achieve this. You can add a disabled range of dates that cannot be selected, but they will be visible. You can achieve this by implementing the OnIsDateTimeDisabled event.
The second way is to use the pmCustom planner mode that can be used in combination with CustomDateTimes list as demonstrated in the following sample.
TMSFNCPlanner1.BeginUpdate; TMSFNCPlanner1.Mode := pmCustom; for I := 0 to 8 do TMSFNCPlanner1.CustomDateTimes.Add(IncMinute(EncodeDateTime(2017, 2, 22, 11, 0, 0, 0), 15 * I)); for I := 0 to 9 do TMSFNCPlanner1.CustomDateTimes.Add(IncMinute(EncodeDateTime(2017, 2, 22, 14, 0, 0, 0), 20 * I)); TMSFNCPlanner1.TimeLine.DisplayUnitFormat := ''h mm AMPM''; TMSFNCPlanner1.TimeLineAppearance.LeftSize := 80; TMSFNCPlanner1.EndUpdate;