I have set a time using the hh:mm:ss format in the variable a and set whatever the current time is in the variable in x, same format. And in a if statement if the current time is less then the set time i want it to outprint how many hh:mm:ss it will take to get to the set a value. Thanks
a.setHours(7);
a.setMinutes(45);
a.setSeconds(00);
currenttime.format(x);
if (x.compareTo(a)<0); //x is current time (hh:mm:ss)
{
//how do you outprint difference between x and a
System.out.print("You have event in: " x);
}
if (x.compareTo(a)>0 && x.compareTo(a1)<0)
{
}