I need to set the time on the current date. The time string is always in 24 hour format but the result I get is wrong:
SimpleDateFormat df = new SimpleDate
Replace this:
c1.set(Calendar.HOUR, d1.getHours());
with this:
c1.set(Calendar.HOUR_OF_DAY, d1.getHours());
Calendar.HOUR is strictly for 12 hours.