VBA; A macro that can look into 2 cells and add time of how much it being placed

ItsCasperX

New Member
Joined
Mar 7, 2022
Messages
7
Office Version
  1. 365
Platform
  1. Windows
So, I’m making a sheet that is named (Sheet 1) at the moment and I have 4 settings of time there is 5,15,30,60mins on cell (N11). It starts and ends at 14:00-18:00, the increments of time that I have above is what it goes based on. So if the cell says “5 mins” then it will go like 14:05,14:10 all the way to 18:00.
But i Need to help adding onto more time, somedays we have to add another 15,30,60 to that time frame, so instead of it being 14:00-18:00 it will be 14:00-18:15 & 14:00-18:30 & 14:00-19:00, but I want it to follow the increments of the time that is being followed. so, if it goes by 5mins but we need to go up by 30 mins(14:00-18:30) I want it to be 30mins but with a increment of 5mins, so it will be 18:05, 18:10, 18:15, to 18:30. Can someone help me with it.
 

Excel Facts

What is the fastest way to copy a formula?
If A2:A50000 contain data. Enter a formula in B2. Select B2. Double-click the Fill Handle and Excel will shoot the formula down to B50000.

Forum statistics

Threads
1,214,797
Messages
6,121,629
Members
449,041
Latest member
Postman24

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top