UIDatePicker setting minimum and maximum hour

前端 未结 4 679
孤独总比滥情好
孤独总比滥情好 2021-01-17 03:07

How to set minimum and maximum hour to UIDatePicker ? At all is it possible ?

I know how to set minimum and maximum date:

[datePicker setMinimumDate: today];

4条回答
  •  轮回少年
    2021-01-17 03:36

    You have to make sure that time in your minimum date is 8 am & 10 pm in maximum date. NSDateFormatter will help you to create your date objects as you want.

提交回复
热议问题