Conditionally format in code and count at same time
After reading quite a few posts I see there is no way to count the number of
color entries in a worksheet €“ and have the numbers update €ślive€ť and
automatically as coloring changes. This is a problem for my requirements, in
addition to some other functionality that my worksheet requires. Hopefully
someone can take this on!!
What Im trying to do is to highlight overdue tasks, tasks that are due
within the next seven (preferably working) days, tasks due in 2 weeks time,
and show a summary of these (and thus progress against the project) in a
Red/Green/Yellow table.
The worksheet has a number of cells where the user will enter a dates for
when a task is due and when the task is complete. These date cells have the
€śCalcProgress€ť style applied to them. I want to highlight the due dates in
green and red, and automatically total the number of these coloured entries
in the worksheet and update the totals as they change.
For example:
Total Red Cells: nnn
Total Green Cells: nnn
Total Yellow Cells: nnn
If the due date is <=Today() , the font should be red, bold
If the due date is < =TODAY()+7, the font should be yellow bold
If the due date is < =TODAY()+14, the font should be green (black, not bold)
HOWEVER!! When the user enters a date in the €śDate Complete€ť cell for the
item, due date colouring should revert to plain text (normal). As the €śDate
Complete€ť cells are filled, the total count of red, green and yellow cells
would decrease accordingly.
Hope this is understandable €“ and possible!!
Any assistance will be really, really appreciated!
|