How to use the DateUtils methods to get the relative timing. Precisely, "yesterday, 12:13 PM" but the relative timing yesterday is shown if the event time and the current time difference is 24 hrs.
In my case if the event time is 2016-07-04 21:08:30 and current time is 2016-07-05 21:00:00 the result shows "yesterday". but if I change the event time to be 2016-07-04 20:08:30 (more than 24hrs diff) then it shows 4 Jul, 9:08 PM
Want the relative time to be yesterday on both the cases. How do I achieve that?
CharSequence cs = DateUtils.getRelativeDateTimeString(
This is the code snippet I've used to get the above explained case.