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

Vote for your favorite vizzies from the Power BI Dataviz World Championship submissions. Vote now!

Reply
Anusha__v
Advocate I
Advocate I

Paginated Report Line Chart – Series Color Expression Not Applying Correctly Per Legend

Hi All,
I am working on a Power BI Paginated Report and using a Line Chart with Product Name as the Legend.

I have configured a Color expression for the series, for example:

  • If ProductName = 'A' → Blue

  • If ProductName = 'B' → Red

  • If ProductName = 'C' → Green
    (and so on, total ~6 products / colors)

The expression is defined in:
Chart → Series Properties → Fill → Color → Expression

However, the issue I am facing is:

  • The colors defined in the expression are not consistently applied to the correct legend values

  • For example:

    • Product A is sometimes rendered in Red instead of Blue

    • Product B may take another product’s color

  • It looks like the colors are being assigned based on rendering order rather than the actual ProductName condition

Expected Behavior

Each legend value should always use the color defined in the expression:

  • Product A → Blue

  • Product B → Red

  • Product C → Green

Actual Behavior

Colors are mismatched across legend items even though the expression logic is correct.

Questions

  1. Is this a known limitation or bug in Paginated Reports line charts?

  2. Is there a recommended way to force deterministic color mapping per legend value?

  3. Should the color expression be applied at a different level (e.g., series group instead of series)?

  4. Are there any workarounds (such as sorting, hidden groups, or custom palettes)?

Any guidance or confirmation would be appreciated.

Thanks,
Anusha. V

1 ACCEPTED SOLUTION

Hi @Anusha__v , Thank you for reaching out to the Microsoft Community Forum.

 

This is a known limitation. In SSRS / Power BI Paginated Reports, when a line chart uses a dynamic legend (series group), colours are assigned to series instances at render time. Those instances are created and reused based on internal rendering order, not permanently bound to a specific legend value like ProductName. As a result, even correct colour expressions can appear to move between products when the data shape or render order changes. Sorting the dataset, series group or returning the colour from the dataset may not fix this, because the renderer does not maintain a stable key-to-color mapping.

 

If you need deterministic colours, the only reliable solution is to avoid a dynamic series group. Define one static series per product (or pivot the data so each product is its own value column) and set the colour directly on each series. This forces a one-to-one relationship between product and series and guarantees consistent legend colours. With a fully dynamic legend, there is currently no supported way in paginated reports to lock colours to specific legend values.

View solution in original post

3 REPLIES 3
rohit1991
Super User
Super User

Hii @Anusha__v 

 

To get deterministic colors, the usual workaround is to create a separate series group per product (or per color group), or return the color from the dataset and bind it at the series group level, ensuring stable sorting. Applying the expression only at the series level without a fixed grouping will remain non-deterministic.


Did it work? ✔ Give a Kudo • Mark as Solution – help others too!

Hi @rohit1991 ,
 Color from the dataset and bind it at the series group level. Sorting is not helping still the same issue.

Hi @Anusha__v , Thank you for reaching out to the Microsoft Community Forum.

 

This is a known limitation. In SSRS / Power BI Paginated Reports, when a line chart uses a dynamic legend (series group), colours are assigned to series instances at render time. Those instances are created and reused based on internal rendering order, not permanently bound to a specific legend value like ProductName. As a result, even correct colour expressions can appear to move between products when the data shape or render order changes. Sorting the dataset, series group or returning the colour from the dataset may not fix this, because the renderer does not maintain a stable key-to-color mapping.

 

If you need deterministic colours, the only reliable solution is to avoid a dynamic series group. Define one static series per product (or pivot the data so each product is its own value column) and set the colour directly on each series. This forces a one-to-one relationship between product and series and guarantees consistent legend colours. With a fully dynamic legend, there is currently no supported way in paginated reports to lock colours to specific legend values.

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

Vote for your favorite vizzies from the Power BI World Championship submissions!

Sticker Challenge 2026 Carousel

Join our Community Sticker Challenge 2026

If you love stickers, then you will definitely want to check out our Community Sticker Challenge!

January Power BI Update Carousel

Power BI Monthly Update - January 2026

Check out the January 2026 Power BI update to learn about new features.

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.

Users online (4,763)