Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Custom DatePicker

I ve been stuck on a DatePicker problem for several and i can't seem to find any solution.

I currently have a DatePickerDialog which fits quite well to my needs YET I also need to be able to hide / disable Both Day and Month field (in order to select a Month or a Year), I can't find any solution except implementing my own MonthPicker/yearPicker . the fact is I don't really know where to begin with to write a picker which has the same style as the default one.

I would be glad if any of you have sample code of custom date picjer or any simpler Idea to get to cope with my problem.

Thanks a lot

hush

like image 865
Hush Avatar asked Aug 12 '10 09:08

Hush


1 Answers

My idea is using a custom Date Picker for android. In Google Code, I found an open source project called Android Wheel

Android wheel for date time picker

After checkout source code from Google Code, you'll find several example so that you can easily customize a year-picker as you want.

like image 167
anticafe Avatar answered Oct 02 '22 13:10

anticafe