As Norm suggested, just get the time in milliseconds (Calendar.getTimeInMillis() - the Date class has a similar method) and compare the returned long value. Seems a much easier alternative