Check your eligibility for this 50% exam voucher offer and join us for free live learning sessions to get prepared for Exam DP-700.
Get StartedJoin us at the 2025 Microsoft Fabric Community Conference. March 31 - April 2, Las Vegas, Nevada. Use code FABINSIDER for $400 discount. Register now
Since importing the Office Theme Colors from "%appdata%\Microsoft\Templates\Document Themes\Theme Colors" is not possible, I have created an Excel file and some VBA that converts the selected Office Theme Colors into a Power BI Desktop Report Theme. Simply follow these four easy steps:
Select the color palette you want to convert via Page Layout > Themes > Colors
Select the color palette in the Page Layout tab
The Report Theme JSON file needs the color codes in hexadecimal format. Just click the button “Generate Hex-Codes for Colors” and a few lines of VBA will fill the cells D9 to D20. Since the JSON file needs the hexcodes in double quotes and prefixed by a hashtag, the VBA code adds them as well.
The Office Theme Colors and their corresponding hexcodes
Enter a name for your theme in cell F18. The JSON file will be saved (see step 4) under this name so refrain from using special characters.
The formula in B25 uses the hexcodes from cells D9 to D20 to create the text for the JSON file:
Cell B25 shows a preview of your JSON file
Now click the “Save as JSON” button and select a folder where you want to save it.
If you have any suggestions for improvements, I am more than happy to hear from you and implement them!
Dominik Petri
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.