im trying to code a program at the minute which when you set specific times to switch something on in this case a boiler (theretically)
So i need to have a switch on time and switch off time therefore i have used JComboBoxes then used a
string array to hold the value for hours and minutes and then converted them into an interger for to use for if statements.
Now im quite stumped on what to do next i know i have to compare the times together with a realtime clock therefore i guess using the swing calender function???
So far i have come up with this code but even the simple if statement fails me it always reads ON even trying different cominations of >= <= == etc.... im a bit stuck how to compare the times. I would also like it to keep checking to see whether the boiler should still be active therefore i guess putting the whole thing into an infinate for loop?
Any tips or ideas would be greatful

i have embedded my code for you to all look at also i am not the best programmer i will admit that and i have limited knowledge but any help would be helpful.