views:

1393

answers:

3

Hello, Is there any android widget that enable to pick the date and the time at the same time ? I already use the basic date picker and date picker:

http://developer.android.com/guide/tutorials/views/hello-timepicker.html
http://developer.android.com/guide/tutorials/views/hello-datepicker.html

but they are not that sexy and user friendly (I found). Do you know if a widget including both date and time exists? Thanks a lot, Luc

+2  A: 

There is nothing built into Android that offers this.

CommonsWare
ok... that's a pity :(
Luc
+3  A: 

The URLs you link to show how to pop up a dialog with a time picker and another dialog with a date picker. However you need to be aware that you can use those UI widgets directly in your own layout. You could build your own dialog that includes both a TimePicker and DatePicker in the same view, thus accomplishing what I think you are looking for.

In other words, instead of using TimePickerDialog and DatePickerDialog, just use the UI widgets TimePicker and DatePicker directly in your own dialog or activity.

mbaird
A: 

I was facing the same problem in one of my projects and have decided to make a custom widget that has both the date and the time picker in one user-friendly dialog. You can get the source code along with an example at http://code.google.com/p/datetimepicker/. The code is licensed under Apache 2.0.

ptashek
Thanks a lot, I will definitively have a look.
Luc