Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Two different color in single bar in barchart

Dear All,

My requirement is, i want to show two values in single bar chart with different colors like below.

I have two expression fields capacity &used and single dimension field container.

Say for example the container A ( My dimension ) of capacity 100% is filled with 30%.I want to differentiate the bar in two colors.

100 should be in one color and in that 30 should be in an another color ( like color in color in single bar ) Like below.

Thanks in advance

Comm.jpg

11 Replies
sunny_talwar

I guess you just need to stack the two charts. and you can do this on the style tab of the chart properties.

Expression1 : Filled Expression

Expression2: Total Capacity Expression - Filled Expression

and select stacked on the style tab

ThornOfCrowns
Specialist II
Specialist II

I don't think that's possible. You'll have to either use a stacked chart or have two charts and layer them, I think.

syukyo_zhu
Creator III
Creator III

Hi,

You can go to your expression,

then background color as attached image. hope helpfulbackground.png

sunny_talwar

Something like the attached?

Capture.PNG

Not applicable
Author

Dear Sunny,  I tried this. but i need like what i asked. any possibilites ?
Not applicable
Author

Dear James,  I tried this too. layering of two charts is not accepted in my case.  Thanks for your reply.
sunny_talwar

I guess I am not sure I understand the requirement, would you be able to elaborate?

Not applicable
Author

I have to use the expression only in color sections like back ground color or colors tab instead of expression section to show the used area in different color in same bar.
Not applicable
Author

Thanks for your response Sunny.