Thank you Melonie. I have been staring at this code for so long and I have missed the obvious....defining actions for the values 14 and 18 fixed it.