Disable/Hide Year from DatePickerDialog in android
DatePickerDialog in Android is the most essential part . We can easily customize DatePickerDialog in Android . Here is the example to disable/hide Year from DatePickerDialog in Android . The given bellow code will work from API 5.0+ DatePickerDialog Constructor : 1. Context : Require Application context 2. new DatePickerDialog.OnDateSetListener(){ onDataSet() // this method execute when user select date and press ok button { a. Year // selected year b. Month // selected month , it's return previous month. Suppose you select March then it return 2 insted of 3 . c. Day // selected date } } ...