How to Add More Absence Type Keys to an Excel Employee Schedule
Question details
The user needs to add new custom absence type codes and corresponding color formatting to an existing Excel Employee Absence Schedule.

- Product
- Excel
- Device & OS
- not provided
- Scenario
- Customizing an employee attendance or absence tracking spreadsheet to include additional categories beyond the default template options.
- Observed behavior
- The schedule requires extending the legend with new named keys, assigning specific colors and descriptions, and linking them to conditional formatting rules across all monthly worksheets.
Make a backup copy of your original Employee Absence Schedule workbook before modifying named ranges and conditional formatting rules to prevent accidental data loss or broken formatting.
Create New Named Keys and Apply Conditional Formatting
By defining a new named range for your absence code and applying a custom conditional formatting rule, you can track new absence types across your entire yearly schedule.
This method involves manually adding a new entry to the schedule's legend, naming the cell so formulas can reference it, and setting up a formatting rule that highlights cells matching your new code.
Navigate to the January worksheet. Select an empty cell in the legend area (e.g., V2) and type your new absence code (such as 'Z'). Next, give this cell a unique defined name that begins with 'Key' (for example, 'KeyNewAbsence') using the Name Box next to the formula bar.
Apply a specific fill color to the new key cell. Select the adjacent cells (such as W2:Y2), merge them, and type a clear description for the absence type so users understand what the code means.
Highlight the entire date grid where absence codes will be entered. Go to the Home tab, click Conditional Formatting, and choose New Rule. Select 'Use a formula to determine which cells to format'.
Enter a formula that checks if the cell matches your new key, such as =C7=KeyNewAbsence (assuming C7 is the top-left cell of your selected range). Click Format, select the exact same fill color you applied to the legend key, and click OK.
To ensure the tracking works year-round, you must manually repeat this key creation and conditional formatting setup on the individual worksheets for February through December.

Customize Your Employee Schedule with WPS Spreadsheet
WPS Spreadsheet provides intuitive tools for managing named ranges and conditional formatting, making it incredibly easy to track employee absences and customize complex schedule templates.
- 1. Open your schedule template: Launch WPS Spreadsheet and open your Employee Absence Schedule file.
- 2. Create your new key: Type your new absence code in the legend area, define its name in the Name Box, and apply your desired background color.
- 3. Add a formatting rule: Select your schedule grid, navigate to Home > Conditional Formatting > New Rule, and choose the formula option.
- 4. Apply and save: Input your matching formula (e.g., =C7=KeyName), set the matching format color, and click OK to instantly apply the changes.

Frequently Asked Questions
How do I edit an existing conditional formatting rule in my schedule?
Go to the Home tab, click Conditional Formatting, and select Manage Rules. From there, select the rule you want to modify, click Edit Rule, and update either the formula or the color format.
Why isn't the color changing when I type the new absence code into the schedule?
This usually happens if the conditional formatting formula does not accurately reference the named key (e.g., a typo in the name), or if the rule's 'Applies to' range does not cover the cell where you are typing. Double-check your formula and the selected range in the Conditional Formatting Rules Manager.
Can I apply the same conditional formatting to all monthly sheets at the same time?
While you can group sheets to enter data simultaneously, conditional formatting rules and named ranges tied to specific sheet scopes often require you to set them up individually per sheet to ensure the references do not break in complex templates.
How do I delete an absence key I no longer need?
First, delete the code and description from your legend. Next, go to the Formulas tab and open the Name Manager to delete the named range. Finally, remove the associated color rule by going to Home > Conditional Formatting > Manage Rules and deleting the specific rule.




