Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Grow your Fabric skills and prepare for the DP-600 certification exam by completing the latest Microsoft Fabric challenge.

Reply
gooranga1
Power Participant
Power Participant

theme row grand total formatting no longer working

Hi ,

I have a basic theme I use and have used for years. It has always worked pretty well. I have just noticed that it is no longer formatting grand totals in a matrix properly anymore.

 

I was using the below (which is just a snippet) json which always did the trick but now it doesn't.

 

"visualStyles": {
 "*": {
      "*": {
        "*": [

 "total": [
          {
            "fontColor": {
              "solid": {
                "color": "#FFF"
              }
            },
            "backColor": {
              "solid": {
                "color": "#215AA8"
              }
            },
		"fontSize": 12
          }
        ]

     }
    }

}

 I also tried adding this to the theme file as a test to see if that was an issue but the grand total remains unchanged.

"pivotTable": {
			"*": {
				"subTotals": [{
					"backColor": { "solid": { "color": "#01B8AA"}}
				}],
				"total": [{
					"fontSize": 14,
					"fontFamily": "Courier New"
					}]
			}
  }

 Does anyone know what the settings are (if any ) for these properties in a theme file?

Grandtotal.png

2 ACCEPTED SOLUTIONS

I would appreciate it if you can accept my answer as the solution. Thanks in advance.

View solution in original post

gooranga1
Power Participant
Power Participant

I was using the url to try to set these which is excellent but now looks slightly out of date now.

PowerBI-ThemeTemplates/Matrix.json at master · deldersveld/PowerBI-ThemeTemplates · GitHub 

I used this to set the Totals for columns and rows

   "pivotTable":{
         "*":{
            "rowTotal":[
               {
                  "fontColor":{"solid":{"color":"#FFFFFF"}},
				  "fontFamily":"Calibri",
                  "backColor":{"solid":{"color":"#4B4F54"}},
                
			      "applyToHeaders": true,
		          "fontSize": 12				  
			   }],
			   "columnTotal":[
               {
                  "fontColor":{"solid":{"color":"#FFFFFF"}},
				  "fontFamily":"Calibri",
                  "backColor":{"solid":{"color":"#4B4F54"}},
                
			      "applyToHeaders": true,
		          "fontSize": 12				  
			   }]
         }
      }

 

View solution in original post

9 REPLIES 9
gooranga1
Power Participant
Power Participant

I was using the url to try to set these which is excellent but now looks slightly out of date now.

PowerBI-ThemeTemplates/Matrix.json at master · deldersveld/PowerBI-ThemeTemplates · GitHub 

I used this to set the Totals for columns and rows

   "pivotTable":{
         "*":{
            "rowTotal":[
               {
                  "fontColor":{"solid":{"color":"#FFFFFF"}},
				  "fontFamily":"Calibri",
                  "backColor":{"solid":{"color":"#4B4F54"}},
                
			      "applyToHeaders": true,
		          "fontSize": 12				  
			   }],
			   "columnTotal":[
               {
                  "fontColor":{"solid":{"color":"#FFFFFF"}},
				  "fontFamily":"Calibri",
                  "backColor":{"solid":{"color":"#4B4F54"}},
                
			      "applyToHeaders": true,
		          "fontSize": 12				  
			   }]
         }
      }

 

gooranga1
Power Participant
Power Participant

@Typhoon74 sorry I didn't flag you answer as a solution which it was in 2022, now with all the recent upgrades I had to remove all my textClasses inputs as it threw an error on import. Now I am back in the same boat. using the totals tag in pivotTable doesn't seem to make the slightest difference???

gooranga1
Power Participant
Power Participant

So now I have got most of this working but for some reason I can modify the fontSize ok, but whatever I do I cannot modify the fontFamily. I use this code which changes the size but not the font itself. Anyone point me in the right direction?

Subtotal.png

 

  "visualStyles": {
	"pivotTable": {
			"*": {
		    "subTotals": [
          {
			"rowSubtotals": true,
			"columnSubtotals": true,
            "fontColor": {
              "solid": {
                "color": "#FFF"
              }
            },
            "fontFamily": "Calibri",
			"backColor": {
              "solid": {
                "color": "#44B2E8"
              }
            },
			
			
			"fontSize": 10,
			"applyToHeaders": true,
			"rowSubtotalsPosition": "Top",
			"perRowLevel": false,
			"perColumnLevel": false	
          }
        ],
		"values": [{
			"fontFamily": "Calibri",
			"fontSize": 10
		}]
	}
		}

 

Hi @gooranga1 ,
I have a related question, did you figure out how to enable Apply to Label in the JSON file?
That is what I am currently struggling with.

Thanks Dirk

@Typhoon74  no I have worked it out either!

gooranga1
Power Participant
Power Participant

it seems it is rowTotal

If you don't need to have a different font type and font size you can define it globally in the textClasses

 

 "textClasses":{
"label":{
"fontFace":"Calibri","fontSize":11
},
"callout":{
"fontFace":"Calibri"
},
"title":{
"fontFace":"Calibri"
},
"header":{
"fontFace":"Calibri"
}
},

 

Hi @Typhoon74 yes thanks I tried that and it seems to do what I need, I just thought you could get more control of individual visualisations but it doesn't look like we do.

I would appreciate it if you can accept my answer as the solution. Thanks in advance.

Helpful resources

Announcements
RTI Forums Carousel3

New forum boards available in Real-Time Intelligence.

Ask questions in Eventhouse and KQL, Eventstream, and Reflex.

MayPowerBICarousel

Power BI Monthly Update - May 2024

Check out the May 2024 Power BI update to learn about new features.