I am building an app using swift and in that app there is one field for accepting expiry date for Debit card for payment purpose. How can I accept only month and year by usi
Choice-1
Objective-C
yourDatepicker.datePickerMode = UIDatePickerModeDate;
Swift
yourDatepicker.datePickerMode = UIDatePickerMode.Date
Swift3
yourDatepicker.datePickerMode = .date
the another modes are
Choice-2
the above method not working well, then check this link