Pushbutton to add or substract time from cell

Hi there,
i tried to figure out, and failed miserably over the weekend, to fugure out a faster way of editing my timesheets.

What i have:
A time formatted cell that has a value of “17:00”

What i would be able to do, through a macro or pushbutton, is to add or substract 15 min incriments
from the selected cell.

Have a year of cells to modify, so any idea would be greatly appreciated.

I would be inclined to

  • add a column in which you can enter the number of quarter hour increments (negative or postive) by which you need to change the time.
  • Add another column to do the calculation for you. There are 96 quarter hours in a day so where 17:00 is in A1 and B1 has -1 then in C1 enter =A1+B1/96, it will show a result of 16:45

spin_button_time.ods (16.5 KB)

I’d suggest to use data-validation instead of a button. If you put the allowed values in a separate list you may choose from them by arrow-key after you activated the dropdown with Alt-ArrowDown
.
As @EarnestAl already pointed out there are only 96 values and your list may even shorter, if not all times are possible.
.
I attached a small sample to test: select a1, then hit alt+arrow-down to access the list.
Time-validation.ods (9.5 KB)

2 Likes