Fixes Microsoft Excel appearance when custom Windows theme is used.
When the custom dark Windows theme is used, sheets, graphics items, charts and everything that have an "Automatic color" are displayed, exported and printed in the wrong colors.
This happens because Excel picks system colors (instead of using predefined ones) for the "Automatic color" which are altered by the themes.
This Add-In aims to fix this issue by setting colors to normal.
Check out project's DeviantArt page for general discussion.
If you find this Add-In useful, you also might want to get PowerPointDarkThemeFix.
- Sheets
- Cells
- Graphic shapes
- Charts - except slightly different font colors
- Styles
- Fixing multiple files in one click
- Charts' font colors - there's an option to set it to black.
- Cell's dark background when editing - there's an option to fix it, but you won't be able to undo anything. As an alternative, use the formula thingy right above the sheet to see what you type.
- Different cells' fill outside of used range - fill can be either preserved (including an actual automatic color, default behavior) or removed completely. There's an option to tweak it.
- OLE Excel objects - you need to manually open it, save and close.
Enabling configurable options is described under the Configuration section.
- Colors may still be wrong - some Excel version will change colors to an arbitrary indexed colors depending on a theme. Not all colors and themes are affected.
- SmartArt - as far as I've tried, unfixable.
- Automatic color replacement - will make things undoable and heavily slow down Excel (if not make it unusable).
- Table styles - impossible to fix built-in styles. Cells with custom styles are being fixed automatically without any issues.
- Altering backgrounds - using background is a part of the fix. There's no way of detecting whether the sheet has a background, so Add-In just will replace it.
- Protected sheets - need to manually unprotect it, click "Fix all" button and, if needed, protect it again.
- Possibly, some of
Shape.Type
s. - You name it, I'm not an Excel expert :D
If you know how to fix any of these things, please, fill out an issue and describe a solution. I will greatly appreciate your effort!
Fully compatible with Microsoft Office 2016, 2019 and 2021 (starting from build 14430.20306).
Reportedly, doesn't fully work in 365, requires installation using "hard way" instructions and has to be put in a localized "AddIns" folder.
If you can test it with Office versions other than listed above, please, fill out an issue and I'll update this list.
Basically, you just need to install an Add-In. You can either stick to the instructions below or google a better guide.
Warning: this method uses XLSTART folder which appears to be working fine, but it's not an exactly correct way to install Add-Ins.
- Download
ExcelDarkThemeFix.xlam
file andExcelDarkThemeFixBG
folder. - Navigate to
%AppData%\Microsoft\Excel\XLSTART
and put bothExcelDarkThemeFix.xlam
andExcelDarkThemeFixBG
here. Do NOT move anything fromExcelDarkThemeFixBG
and don't rename it! - Open Excel and enjoy the Add-In.
If this method didn't work for you, please, create an issue and try method below.
This is more correct way to install an Add-In, but it's hard to follow.
Click to expand
- Download
ExcelDarkThemeFix.xlam
file andExcelDarkThemeFixBG
folder. - "Unblock" Add-In:
- Move the cursor over
ExcelDarkThemeFix.xlam
, click right mouse button and click "Properties". - At the bottom of the window find "Unblock" checkbox and check it. Then click "OK".
- If you don't have this checkbox, please, proceed to the rest of the steps.
- Move the cursor over
- Navigate to
%AppData%\Microsoft\AddIns
and put bothExcelDarkThemeFix.xlam
andExcelDarkThemeFixBG
here. Do NOT move anything fromExcelDarkThemeFixBG
and don't rename it! - Enable macros:
- Open Excel.
- Navigate to "Options".
- On the left side of the window click "Customize Ribbon".
- On the right side of the window check "Developer" and "Add-Ins" boxes.
- Click "OK" and restart Excel.
- Enable this Add-In:
- Open "Developer" tab.
- Click on "Excel Add-Ins".
- Check the "ExcelDarkThemeFix" box.
- Click "Ok" and restart Excel.
- If Add-In doesn't work:
- If you have an antivirus:
- Add
ExcelDarkThemeFix.xlam
to the exceptions. Some antiviruses might prevent Add-Ins from running. Don't worry, this Add-In won't make you computer explode :p Check the sources if you're unsure. - Restart Excel and see if Add-In now works. If yes, you've installed Add-In, don't follow the steps below.
- Add
- Navigate to "Options".
- On the left side of the window click "Trust Center".
- Click "Trust Center Settings..."
- Now you've got three options, try one after another:
- Unblock from PowerShell:
- Open PowerShell.
- Type
Unblock-File -Path "AppData\Roaming\Microsoft\AddIns\ExcelDarkThemeFix.xlam"
and hit Enter. - Close PowerShell.
- Trust only installed Add-Ins:
- On the left side of the Trust Center window click "Trusted Locations".
- Click "Add Location".
- Click "Browse..."
- Navigate to
%AppData%\Microsoft\AddIns
(find a localized "AddIns" folder for non-English Office 365 verison) and click "OK". - Click "OK" in all opened Excel windows.
- Trust EVERY Add-In you open:
- On the left side of the Trust Center window click "File Block Settings".
- Find "Excel 2007 and later Add-In files" row and uncheck both of the checkboxes. Well, you may uncheck all the rows to make your life easier.
- Click "OK" in all opened Excel windows.
- Unblock from PowerShell:
- Restart Excel.
- If you have an antivirus:
Edge case: If you've just installed MS Office and haven't rebooted, install ExcelDarkThemeFix and reboot your PC.
Add-In does everything automatically. However, if you've set automatic colors to something and don't want to fix it yourself, in Excel:
- Open "Home" tab.
- Locate "Dark theme" section.
- Click "Fix all" button.
- Read text in pop-up dialog. It says that if you click "Yes", you won't be able to undo the changes you've made. The only way to undo something is to close all workbooks without saving and open them again.
- Click "Yes" if you will not need to undo anything.
Note "Fix all" button position is configurable via FixAllButtonInHomeTab
option.
This Add-In provides some cool but unsafe options that you can enable. In order to do this, in Excel:
- Open "Developer" tab.
- Click on "Visual Basic".
- On the left pane, navigate to element displayed on the following screenshot and double-click on it:
You'll see some code. Don't freak out, just follow the instructions in it. Read everything carefully!
When you're done, press Ctrl+S
and restart Excel.
Yes, if your theme uses colors different from white for window and black for text. It is recommended to always use this Add-In with custom themes since one usually doesn't checks the colors.
No.
Note: this question is NOT about high contrast looking themes (they're working fine) but about an actual Windows feature.
Yes, startup will be a bit slower. The more cells you have the bigger the impact.
Note: we can't optimize this by changing the whole used range because we need to modify each individual parameter of each individual cell.
Yes, there's an option for it, see "Configuration" section.
No. It's almost (if not entirely) impossible because there's no way of tracking which cell should use which colors. Same goes for every MS Office application.
Please, fill out an issue on this repository and provide as much information as possible.
If you're regular user, you can test this Add-In with different kinds of workbooks and report found issues, or install an older version of Microsoft Office and check if this Add-In works with it.
You can also spread the word about this Add-In (especially in non-English speaking parts of the Internet), so other people could have a less of a headache.
If you're developer, you can add some useful features or fix things described above. Start by setting DebugLevel
option and thoroughly reading the code to understand what it does. Then do the coding. When you're done, create a pull request with your code. If it's not hard, please, provide the code in plain text instead of .xlam file even if you've changed entire Add-In.