0

So i have this problem of not getting accurate time result from timepicker declared in xml, not the dialog thing, i just wanted to know what is the difference from the two. so that i can know which is better to use on my app, mainly i use the timepicker to set an alarm or a reminder, because i have a hunch that the timpicker declared in xml is just for UI use not really for functionality. because i keep on getting the wrong result, specially dealing with AM and PM, Scenario is that when using timepicker declared in xml (not the dialog), i change first the hour den minutes and lastly the AM and PM, but i won't correctly give me the current time, say i chose 7:30 PM supposedly the value of the hour must be 19 since its 24-hour but instead it gives me 7:30 AM i won't change the AM and PM part thus giving me a wrong result, if you go the other way around, it works, it gives me ang accurate result.

SO my question is what is the MAIN difference between the two timepickers, is it for show(timepicker xml declared) and timepicker(dialog)

Cœur
  • 37,241
  • 25
  • 195
  • 267
lemoncodes
  • 2,371
  • 11
  • 40
  • 66

1 Answers1

0

Please refer to this post for this problem, i just came across this thread and it is really the same with my problem. its a bug issue in Android

Android TimePicker AM/PM button not invoking onTimeChanged

Community
  • 1
  • 1
lemoncodes
  • 2,371
  • 11
  • 40
  • 66