Open mikeld opened 4 years ago
This is the code using DatePickerDialog. It works perfectly in ios < 14 DatePickerDialog().show("Event Date", doneButtonTitle: "Accept", cancelButtonTitle: "Cancel", datePickerMode: .date) { (date) -> Void in if (date != nil) { self.dateEvent = date self.lblDateEvent.text = "(dateFormatter.string(from:date!))" //update map self.showMapPoints() } }
The preferredDatePickerStyle should be set Something like this if #available(iOS 13.4, *) { datePicker.preferredDatePickerStyle = .wheels }
Thank you very much lexin! now works. You are the best.
what is dataPicker in this case?
@lexin what is dataPicker in ur case?
@lexin what is dataPicker in ur case?
I put it in DatePickerDialog.swift
Same here
@lexin I tried adding your fix but I still get a similar image as OP. Anyone else also facing this?
Go to DatePickerDialog.swift in Sources Folder and add this line if #available(iOS 13.4, *) { datePicker.preferredDatePickerStyle = .wheels } @mehyaz showed in the above image worked for me
worked for me
This line is already in the source, should this issue be closed?
@lexin what is dataPicker in ur case?
I put it in DatePickerDialog.swift
worked for me thanks.
Shows Error @lexin Please Help..
Shows Error @lexin Please Help..
replace the line by
if #available(iOS 13.4, *) { self.datePicker.datePicker.preferredDatePickerStyle = .wheels }
Can't select a date Can you help me please.