cancel
Showing results for 
Search instead for 
Did you mean: 

Change Color of Columns in a Chart with RGB

Former Member
0 Kudos

Hi,

This css script works very well for changing the color of a column in a dual axis column-line combination chart.

.customChart2 g.v-column g.v-datashape:nth-child(1) rect.v-datapoint.v-morphable-datapoint {fill: orange;}

.customChart2 g.v-legend-content g.v-row.ID_0 path {fill: orange;}

.customChart2 g.v-m-main g.v-m-plot g.v-axis1 .v-lines.v-morphable-line:nth-child(1) {fill: silver;}

I need to define the colors with RGB and I tried different versions of this script like ....{ background: (RGB (0, 174, 219);}

But it did not work 😞

I am sure it is pretty easy but I don't know how and just waste time on it.

Thanks in advance for any hint.

Regards,

Deniz

Accepted Solutions (1)

Accepted Solutions (1)

TammyPowlas
Active Contributor
0 Kudos

Try this:

g.v-column g.v-datashape:nth-child(1) rect.v-datapoint.v-morphable-datapoint {fill: rgb(233, 111, 56); !important; }

That is working for me.

Former Member
0 Kudos

Hi Tammy,

Thanks very much for your quick reply. It works fine 🙂

But just let me know why you use !important in your script?

Regards,

Deniz

TammyPowlas
Active Contributor
0 Kudos

Hi Deniz - I saw this on a similar thread.

For background please see What does !important mean in CSS?

Answers (0)