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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Anonymous
Not applicable

Y Axis for Line showing decimal 2 digit values from JSON theme

Hi Team,

 

We are using JSON theme for our Power BI reports and we came across one strange behaviour of Line Chart when it is implemented on that. 

 

Y axis of Line chart showing value with decimal 2 digits (default) with JSON theme even those values are not overriding as well from properties section of Visualisation pane if we are setting manually. 

 

We are using below mentioned code to implement JSON theme there. Could you please let us know if any workaround available to set values from JSON theme of any property which need to be change from Visualisation Pane.  

 

"categoryAxis": [{
"show": true,
"axisType": "categorical",
"labelColor": { "solid": { "color": "#01B8AA"}},
"fontSize": 14,
"fontFamily": "Courier New",
"preferredCategoryWidth": 30,
"maxMarginFactor": 28,
"concatenateLabels": true,
"showAxisTitle": true,
"axisStyle": "showTitleOnly",
"titleColor": { "solid": { "color": "#01B8AA"}},
"titleText": "asdf",
"titleFontSize": 12,
"titleFontFamily": "Segoe UI"
}],
"valueAxis": [{
"show": true,
"position": "Right",
"axisScale": "Linear",
"labelColor": { "solid": { "color": "#01B8AA"}},
"fontSize": 14,
"fontFamily": "Courier New",
"labelDisplayUnits": "0",
"labelPrecision": "None",
"showAxisTitle": true,
"axisStyle": "showTitleOnly",
"color": { "solid": { "color": "01B8AA"}},
"titleText": "asdf",
"titleFontSize": 12,
"titleFontFamily": "Courier New",
"gridlineShow": true,
"gridlineColor": { "solid": { "color": "#01B8AA"}},
"gridlineThickness": 2,
"gridlineStyle": "dashed"
}],
"y2Axis": [{
"secStart": 0,
"secEnd": 2000,
"secFontSize": 16,
"secLabelColor": { "solid": { "color": "#0928DD"}},
"secShowAxisTitle": true,
"secTitleText": "Secondary Value Axis",
"secTitleColor": { "solid": { "color": "#448822"}}
}]

 

Thanks in Advance!!

1 REPLY 1
v-eqin-msft
Community Support
Community Support

Hi @Anonymous ,

 

You may take a look at the post below.

https://community.powerbi.com/t5/Desktop/JSON-theme-Data-label-quot-Display-units-quot-How-to-set-to...

 

Did I answer your question ? Please mark my reply as solution. Thank you very much.

If not, please upload some insensitive data samples and expected output.

 

Best regards,

Eyelyn Qin

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

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

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.

Top Solution Authors
Top Kudoed Authors