Search code examples
xcode4datepicker

How to make a DatePicker View show only date and not time


I have a UIDatePicker which is showing date and time by default.. but i want it in the format of year month and date only.. how to achieve this? Like how it is show in this image

enter image description here


Solution

  • Set the datePickerMode property to UIDatePickerModeDate.