For custom date picker I am using the
https://github.com/squimer/DatePickerDialog-iOS-Swift
its working fine but I need to add two things on this
1.I need to re arrange the components order like date/month/year(i.e 23/05/2016) instead of the month/date/year(i.e 05/23/2016).
2.I need another datepicker object with only two components i.e month/year (may/2016).
How can I achieve this
Thank you in advance
You cannot do this with
UIDatePicker
, and since that project usesUIDatePicker
, you can't do it with that project.UIDatePicker
has extremely limited customization options. You can have it show a date, or a time, or both. But you can't tell it how to display the date, so you can't rearrange the components or choose which date components to show.If you need these formats, you will need use
UIPickerView
and implement your owndelegate
anddataSource
methods to display the options that you need. Or maybe you can find a different open source project that does what you need.