Trevor3007
Well-known Member
- Joined
- Jan 26, 2017
- Messages
- 675
- Office Version
- 365
- Platform
- Windows
Hi,
I have attempted this myself but with my very, very limited VB knowledge, cannot get it to work.
Below is a screenshot from the april2022 worksheet, (starting from jan 2022 - feb2023) . its a rather tedious job to colour each cell pne by one with the applicbale background. Can some super VB person come up with solurion to change the cell based on the text within ( for exampe where 'R and Off' is placed in a cell that cell(s) will change the background to yellow) One of the issues I found is when W falls on weekend this must turn 'green' whereas when 'w' is on a mon - friday its white , unless its a 'bank hol' which muxt be red ( as should S be too) The rota starts at e5-ah91. Each month has its own tab ( March22, April22 etc). I also thinking about having a worksheet that had the applicable text in col a & col b would have the colur and the code would look to that . For exanple
Col A Col B
Off VByellow
S VBred
E Vblightblue
H VBpurple
i don my virtual hat to the person(s) who can solve this as ( to me) its not an easy solution?
many thanks in advance
I have attempted this myself but with my very, very limited VB knowledge, cannot get it to work.
Below is a screenshot from the april2022 worksheet, (starting from jan 2022 - feb2023) . its a rather tedious job to colour each cell pne by one with the applicbale background. Can some super VB person come up with solurion to change the cell based on the text within ( for exampe where 'R and Off' is placed in a cell that cell(s) will change the background to yellow) One of the issues I found is when W falls on weekend this must turn 'green' whereas when 'w' is on a mon - friday its white , unless its a 'bank hol' which muxt be red ( as should S be too) The rota starts at e5-ah91. Each month has its own tab ( March22, April22 etc). I also thinking about having a worksheet that had the applicable text in col a & col b would have the colur and the code would look to that . For exanple
Col A Col B
Off VByellow
S VBred
E Vblightblue
H VBpurple
i don my virtual hat to the person(s) who can solve this as ( to me) its not an easy solution?
many thanks in advance