vara vara - 1 year ago 205
Swift Question

SBDatePicker Its posssible to set minimum date and maximum date in swift?

I am new for developing the ios application, I have used SBPickerSelector in Cocapods framework for Selecting datePicker.
whether If possible to set the MinumDate and MaximumDate???

Answer Source


let picker: SBPickerSelector = SBPickerSelector.picker()

//Minimum Date
picker.datePickerView.minimumDate = NSDate(); // A date

//Maximum Date
picker.datePickerView.maximumDate = NSDate(); // An other date ;
//or picker.setMaximumDateAllowed(NSDate())
Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download