calculate dates based on company and active

RSnap3232

New Member
Joined
Nov 20, 2020
Messages
43
Office Version
  1. 2016
  2. 2013
Platform
  1. Windows
hello All,

I have the below that works out whether or not a company charges weekends/ bank holidays but I now need to modify it to also include a running count on days if the product is still being used ie =Today() if product is active (still only calculating whether they charge weekends or not) or use end date if product is Closed. Any idea?

1613472249392.png
 

Excel Facts

Is there a shortcut key for strikethrough?
Ctrl+S is used for Save. Ctrl+5 is used for Strikethrough. Why Ctrl+5? When you use hashmarks to count |||| is 4, strike through to mean 5.
M2 shows the running total, but will stop growing after 12/31/21 (in this case) when the end date is passed.

MrExcelPlayground.xlsx
KLM
1Running
2days:26133
3Holidays
4Start1/1/20211/18/2021
5End12/31/202112/25/2021
6CompanyB company7/31/2021
711/23/2021
87/4/2021
9
10CompanyUses bank holiday
11A companyTRUE
12B companyFALSE
13C CompanyTRUE
Sheet10
Cell Formulas
RangeFormula
L2L2=IF(VLOOKUP(L6,K11:L13,2,FALSE),NETWORKDAYS(L4,L5,M4:M8),NETWORKDAYS(L4,L5))
M2M2=IF(VLOOKUP(L6,K11:L13,2,FALSE),NETWORKDAYS(L4,MIN(L5,TODAY()),M4:M8),NETWORKDAYS(L4,MIN(L5,TODAY())))
 
Upvote 0
Solution
M2 shows the running total, but will stop growing after 12/31/21 (in this case) when the end date is passed.

MrExcelPlayground.xlsx
KLM
1Running
2days:26133
3Holidays
4Start1/1/20211/18/2021
5End12/31/202112/25/2021
6CompanyB company7/31/2021
711/23/2021
87/4/2021
9
10CompanyUses bank holiday
11A companyTRUE
12B companyFALSE
13C CompanyTRUE
Sheet10
Cell Formulas
RangeFormula
L2L2=IF(VLOOKUP(L6,K11:L13,2,FALSE),NETWORKDAYS(L4,L5,M4:M8),NETWORKDAYS(L4,L5))
M2M2=IF(VLOOKUP(L6,K11:L13,2,FALSE),NETWORKDAYS(L4,MIN(L5,TODAY()),M4:M8),NETWORKDAYS(L4,MIN(L5,TODAY())))
thank you kindly sir that is brilliant
 
Upvote 0

Forum statistics

Threads
1,214,787
Messages
6,121,569
Members
449,038
Latest member
Guest1337

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