Hello All I want to create a dialog from which I can set date and time together.How can I do this
Thanks in advance
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Create a layout consisting of a DatePicker and a TimePicker in fx a LinearLayout with the orientation set to vertical.
Then use this layout to create your dialog.
To react to user interacting with your timepicker, do something like this:
To get the values from the date- and timepicker when the user has finished setting them, add an OK button in your dialog, and then read the date and time values from the Date- and TimePicker when the user presses OK.