I have two time pickers, Start Time & End Time. What I want is for the user to set there own start time and end time. Than I want to add the two times together to get the total time. For example: the user makes the start time 2:00 and end time 4:00. I want the total time to equal 6:00. How is this possible.
Asked
Active
Viewed 99 times
0
-
1When the user sets the time pickers you simply get the values and do the math using them. See [Timepicker](http://developer.android.com/reference/android/widget/TimePicker.html). – DigitalNinja Mar 25 '15 at 00:40
-
1Why would you want it to be 6.00? not 2 hours? – Niko Adrianus Yuwono Mar 25 '15 at 00:52
-
possible duplicate http://stackoverflow.com/questions/18908738/calculate-difference-between-two-times-android – Jimmy Mar 25 '15 at 02:22
-
Total amount of hours for community service needs to add up all time thats why I need it to be 6:00 but I also need to figure out how to make it 2:00 as well – JZ Developers Mar 26 '15 at 00:12