cancel
Showing results for 
Search instead for 
Did you mean: 

Chart series color

shlomi_weiss2
Participant
0 Kudos

Hi

I have a simple bar chart and I want all of it's bars to have the same color.

Is that possible?

Any ideas on how to achieve that?

Regards

Shlomi

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi Shlomi,

Yes, it is possible.

Design Studio 1.3:

  • Option 1 (typical use case: if your dimension doesn't have too much different values and it has the same values - no new values are added dynamically, for example you have applied a background filter to max. 20 fixed dimension values): Chart > Additional Properties > Data Series: here you can define a different color for each dimension value; you would define the same color for each dimension value
  • Option 2 (typical use case: if your dimension has a lot of values which are not fixed in your chart - they change if new data gets loaded or different filters are applied to the data source): Chart > Properties > Display > Conditional Formatting > New Rule...: create a rule where either your measure or dimension meets a condition and choose the color that should be used if the condition is true

Or use CSS in your custom CSS file (should also work in DS 1.2, but I tested it only in DS 1.3):

for example:


/* Chart Type: Bar ; change color for bars */

.v-m-plot .v-bar rect {fill: orange; stroke: white/*brown*/;}

/* Chart Type: Bar ; change color for dimension values in legend */

.v-legend-content path {fill: orange;}

...you can further customize the css with other styling too.

Best Regards,

David

shlomi_weiss2
Participant
0 Kudos

Hi David

Your answer in Option 2 almost did the trick

It does change the bars but the dimension colors stays as it was

The 3rd option works perfectly

Thanks

Shlomi

I've assigned points

Answers (1)

Answers (1)

Former Member
0 Kudos

Are you using the same measure for different attributes? Have you tried "swap dimension"? Otherwise you can select a color in the AdditionalProperties.