cancel
Showing results for 
Search instead for 
Did you mean: 

Java Script Code for Comparison Micro Chart with Color Palette

Former Member
0 Kudos

Hi Experts,

Can you please send the javascript code for micro chart with Color Palette.

Thanks,

Sandeep

Accepted Solutions (1)

Accepted Solutions (1)

saivellanki
Active Contributor
0 Kudos

Hi Sandeep,

Just pass it with color codes in array form of colorPalette property -


new sap.suite.ui.commons.ComparisonChart({colorPalette:["#0089C4","#0008C4"]});

JsDoc Report - SAP UI development Toolkit for HTML5 - API Reference - sap.suite.ui.commons.Compariso...

Regards,

Sai Vellanki.

Answers (2)

Answers (2)

Former Member
0 Kudos

Hi

Thanks for the reply. its working fine.

I have one more requirement. Can you please look in to this

Thanks,

Sandeep

vijay_kumar49
Active Contributor
0 Kudos

You can use the below code to play around with colors in SAPUI5 charts:

plotArea: {

//'colorPalette' : d3.scale.category20().range()

colorPalette :

[

'#00FF00','#FFC200','#FF0000'

]

You can give any color code that you want.