Hi
My app is continuously crashing while setting maximumDate in date picker, this happens only with new iOS 16.0.
I am trying to set minimum and maximum date limit on date picker for accepting birth date, i.e. minimum age 18 years.
Crashing on this line: datePicker.maximumDate = maxDate
Detailed code:
var components: DateComponents = DateComponents()
components.calendar = calendar
components.year = -18
let maxDate: Date = calendar.date(byAdding: components, to: currentDate)!
datePicker.maximumDate = maxDate
Please note, this code works fine in lower version than iOS 16.0.
Xcode: Version 14.0
macOS Monterey Version 12.6
iOS 16.0
Post
Replies
Boosts
Views
Activity
Hi
Can anyone help me out with this extra white space showing in dynamic island iPhones?
Any help is much appreciated.
Thanks.