NSHourCalendarUnit and NSMinuteCalendarUnit are deprecated. How to separate hours and minutes?
I have implemented NSCalendarUnit in my project to separate hours and minutes. Here is the code.
[calendar components:( NSHourCalendarUnit | NSMinuteCalendarUnit | NSSecondCalendarUnit ) fromDate:[df dateFromString:[NSString stringWithFormat:@"%@",workendTime_txtfld.text]]];
In IOS8, NSHourCalendarUnit
, NSMinuteCalendarUnit
, NSSecondCalendarUnit
all of them are now out of date, how to deal with this problem. Please let me know the solution to this problem.
+3
source to share