Hello Team,
Firstly thanks a million for all your help in the past.
I need your help on the below:
I prefer formula(s), but I guess this will work best with a VBA. In the below table, I want to apply a horizontal filter based on Week Number. So If I have selected Week 41, I want to see all 6 departments' dates between 05Oct2020 - 09Oct2020. Rest has to be hidden.
If required can place another table in the file to help VBA choose START DATE & END DATE depending on Year and Week Number. The format I am working is shown below:
Start Date and End Date based on Year and Week Number (I can keep this table hidden somewhere in the sheet)
Firstly thanks a million for all your help in the past.
I need your help on the below:
I prefer formula(s), but I guess this will work best with a VBA. In the below table, I want to apply a horizontal filter based on Week Number. So If I have selected Week 41, I want to see all 6 departments' dates between 05Oct2020 - 09Oct2020. Rest has to be hidden.
If required can place another table in the file to help VBA choose START DATE & END DATE depending on Year and Week Number. The format I am working is shown below:
VBA FOR HORIZONTAL FILTER.xlsx | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
A | B | C | D | E | F | G | H | I | J | K | L | M | N | O | P | Q | R | S | T | U | V | W | X | Y | Z | AA | AB | AC | AD | AE | AF | AG | AH | AI | AJ | AK | AL | AM | AN | AO | AP | AQ | AR | AS | AT | AU | AV | AW | AX | AY | AZ | BA | BB | BC | BD | BE | BF | BG | BH | BI | |||
1 | Week No | Department 1 | Department 2 | Department 3 | Department 4 | Department 5 | Department 6 | Department 1 | Department 2 | Department 3 | Department 4 | Department 5 | Department 6 | ||||||||||||||||||||||||||||||||||||||||||||||||||
2 | 41 | 05-Oct | 06-Oct | 07-Oct | 08-Oct | 09-Oct | 05-Oct | 06-Oct | 07-Oct | 08-Oct | 09-Oct | 05-Oct | 06-Oct | 07-Oct | 08-Oct | 09-Oct | 05-Oct | 06-Oct | 07-Oct | 08-Oct | 09-Oct | 05-Oct | 06-Oct | 07-Oct | 08-Oct | 09-Oct | 05-Oct | 06-Oct | 07-Oct | 08-Oct | 09-Oct | 12-Oct | 13-Oct | 14-Oct | 15-Oct | 16-Oct | 12-Oct | 13-Oct | 14-Oct | 15-Oct | 16-Oct | 12-Oct | 13-Oct | 14-Oct | 15-Oct | 16-Oct | 12-Oct | 13-Oct | 14-Oct | 15-Oct | 16-Oct | 12-Oct | 13-Oct | 14-Oct | 15-Oct | 16-Oct | 12-Oct | 13-Oct | 14-Oct | 15-Oct | 16-Oct | ||
3 | Number of Emplooyes | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
4 | Employees Present | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
5 | Employees Absent | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
6 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
7 | Total Productivity | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
8 | Expected Productivity | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
9 | Actual Producitivty | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
10 | Difference | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
11 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
12 | Quality Scores | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
13 | Expected QA Scores | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
14 | Difference | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
15 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
16 | Client Scores | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
17 | Expected Client Scores | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
18 | Difference | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
19 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Sheet1 |
Start Date and End Date based on Year and Week Number (I can keep this table hidden somewhere in the sheet)
Cell Formulas | ||
---|---|---|
Range | Formula | |
C22:C88 | C22 | =DATE(A22,1,-2)-WEEKDAY(DATE(A22,1,3))+B22*7 |
D22:D88 | D22 | =DATE(A22, 1, -2) - WEEKDAY(DATE(A22, 1, 3)) + B22 * 7 + 4 |