Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
7 years ago
Solved

JSON Theme background color not apply

Hi,   Informations: Powerbi Desktop, version 2.70   My need is simple: I would like to apply a global color background on all reports. To perform this need, i've created a JSON fil with the code...
  • v-qiuyu-msft's avatar
    7 years ago

    Hi Anonymous, 

     

    In your scenario, the "background" means "The background applies to button fill and combo chart label background. How these colors are used depends on the specific visual style that's applied. The table and matrix visuals apply these styles by default." according to this document

     

    In your scenario, if you want to set the page background color via custom theme, you can modify your json file like below: 

     

    {	
        "name": "Custom",
        "dataColors": ["#EE3322", "#FFA300", "#FFEE22", "#C3D600", "#119988", "#7B7EAB", "#B42573", "#998877"],
        "background": "#FFFFFF",
    "visualStyles": {
            "page": {
                "*": {
                    "background": [
                        {
                            "color": {
                                "solid": {
                                    "color": "#000000"
                                }
                            },
                            "transparency": 0
                        }
                    ]
                }
            }
        }
    }

    Reference: 

    https://www.cathrinewilhelmsen.net/2018/12/11/custom-power-bi-themes-page-background-colors/

     

    Best Regards,
    Qiuyun Yu