jag108
Active Member
- Joined
- May 14, 2002
- Messages
- 433
- Office Version
- 365
- 2016
- Platform
- Windows
- MacOS
Hi Team Mr Excel!
I have an interesting situation that I am trying to find a resolution for, I really hope it can be done using VBA."
Anyway here goes. I have a sheet with a list of servers, these servers are auto patched based on Active Directory groups.
With the help From the Mr Excel experts, I have managed to calculate the next date a server(s) will be patched. Not all servers are patched on the same day, but then again there may be more than one server patched on the same day.
Row 1 has a single server that is going to be patched on the 17th, this is fine, I can handle this.
How ever when we get to the situation whereby there are multiple servers to be patched on the 19th, I would ideally like to have the server names added into a list\table to be populated in the meeting request body.
I really hope this can be done?
I have an interesting situation that I am trying to find a resolution for, I really hope it can be done using VBA."
Anyway here goes. I have a sheet with a list of servers, these servers are auto patched based on Active Directory groups.
With the help From the Mr Excel experts, I have managed to calculate the next date a server(s) will be patched. Not all servers are patched on the same day, but then again there may be more than one server patched on the same day.
APG_CLAS.xlsm | |||||||||
---|---|---|---|---|---|---|---|---|---|
A | B | C | D | E | F | G | |||
1 | Host | Patching Group (Rule) | Schedule | Day | Occurance | Current Date | Next Due Date | ||
2 | Server1 | APG-DevTest-ThirdFri-9amTo11am | Third Fri | 5 | 3 | 14/07/2020 | 17/07/2020 | ||
3 | Server2 | APG-DevTest-ThirdSun-2amTo4am | Third Sun | 7 | 3 | 14/07/2020 | 19/07/2020 | ||
4 | Server3 | APG-DevTest-ThirdSun-2amTo4am | Third Sun | 7 | 3 | 14/07/2020 | 19/07/2020 | ||
5 | Server4 | APG-DevTest-ThirdSun-2amTo4am | Third Sun | 7 | 3 | 14/07/2020 | 19/07/2020 | ||
6 | Server5 | APG-DevTest-ThirdSun-2amTo4am | Third Sun | 7 | 3 | 14/07/2020 | 19/07/2020 | ||
7 | Server6 | APG-DevTest-ThirdSun-2amTo4am | Third Sun | 7 | 3 | 14/07/2020 | 19/07/2020 | ||
8 | Server7 | APG-DevTest-ThirdSun-2amTo4am | Third Sun | 7 | 3 | 14/07/2020 | 19/07/2020 | ||
9 | Server8 | APG-DevTest-ThirdSun-2amTo4am | Third Sun | 7 | 3 | 14/07/2020 | 19/07/2020 | ||
10 | Server9 | APG-DevTest-ThirdSun-2amTo4am | Third Sun | 7 | 3 | 14/07/2020 | 19/07/2020 | ||
11 | Server10 | APG-DevTest-ThirdSun-2amTo4am | Third Sun | 7 | 3 | 14/07/2020 | 19/07/2020 | ||
12 | Server11 | APG-DevTest-ThirdSun-2amTo4am | Third Sun | 7 | 3 | 14/07/2020 | 19/07/2020 | ||
13 | Server12 | APG-DevTest-ThirdSun-2amTo4am | Third Sun | 7 | 3 | 14/07/2020 | 19/07/2020 | ||
14 | Server13 | APG-DevTest-ThirdSun-2amTo4am | Third Sun | 7 | 3 | 14/07/2020 | 19/07/2020 | ||
15 | Server14 | APG-Prod-FirstSun-2amTo4am | First Sun | 7 | 1 | 14/07/2020 | 02/08/2020 | ||
16 | Server15 | APG-Prod-FirstSun-2amTo4am | First Sun | 7 | 1 | 14/07/2020 | 02/08/2020 | ||
17 | Server16 | APG-Prod-FirstSun-2amTo4am | First Sun | 7 | 1 | 14/07/2020 | 02/08/2020 | ||
18 | Server17 | APG-Prod-FirstSun-2amTo4am | First Sun | 7 | 1 | 14/07/2020 | 02/08/2020 | ||
19 | Server18 | APG-Prod-FirstSun-2amTo4am | First Sun | 7 | 1 | 14/07/2020 | 02/08/2020 | ||
20 | Server19 | APG-Prod-FirstWed-2amTo3am | First Wed | 3 | 1 | 14/07/2020 | 05/08/2020 | ||
21 | Server20 | APG-Prod-FirstWed-2amTo3am | First Wed | 3 | 1 | 14/07/2020 | 05/08/2020 | ||
22 | Server21 | APG-Prod-FirstWed-2amTo3am | First Wed | 3 | 1 | 14/07/2020 | 05/08/2020 | ||
23 | Server22 | APG-Prod-FourthSun-0amTo2am | Fourth Sun | 7 | 4 | 14/07/2020 | 26/07/2020 | ||
24 | Server23 | APG-Prod-FourthSun-0amTo2am | Fourth Sun | 7 | 4 | 14/07/2020 | 26/07/2020 | ||
25 | Server24 | APG-Prod-FourthSun-0amTo2am | Fourth Sun | 7 | 4 | 14/07/2020 | 26/07/2020 | ||
26 | Server25 | APG-Prod-FourthSun-0amTo2am | Fourth Sun | 7 | 4 | 14/07/2020 | 26/07/2020 | ||
27 | Server26 | APG-Prod-FourthSun-0amTo2am | Fourth Sun | 7 | 4 | 14/07/2020 | 26/07/2020 | ||
28 | Server27 | APG-Prod-FourthSun-0amTo2am | Fourth Sun | 7 | 4 | 14/07/2020 | 26/07/2020 | ||
29 | Server28 | APG-Prod-FourthSun-2amTo4am | Fourth Sun | 7 | 4 | 14/07/2020 | 26/07/2020 | ||
30 | Server29 | APG-Prod-FourthSun-2amTo4am | Fourth Sun | 7 | 4 | 14/07/2020 | 26/07/2020 | ||
Sheet2 |
Cell Formulas | ||
---|---|---|
Range | Formula | |
F23:F27,F2:F14 | F2 | =NOW() |
G2:G30 | G2 | =INT((EOMONTH(F2,--(INT((F2-DAY(F2)+7-MOD(D2+1,7))/7)*7+MOD(D2+1,7)+(E2-1)*7<F2)-1)+7-MOD(D2+1,7))/7)*7+MOD(D2+1,7)+(E2-1)*7 |
F28:F30,F15:F22 | F15 | =TODAY() |
Row 1 has a single server that is going to be patched on the 17th, this is fine, I can handle this.
How ever when we get to the situation whereby there are multiple servers to be patched on the 19th, I would ideally like to have the server names added into a list\table to be populated in the meeting request body.
I really hope this can be done?