Solved

Alternate background color - line item _ REPORTS


Userlevel 1
Badge

Hello,
 

Trying to have the report printed with alternate color for line items to make it easier for user to read the printed report.

 

picking list report for instance.

  Thanks!

icon

Best answer by BenjaminCrisman 6 December 2022, 16:34

View original

10 replies

Userlevel 5
Badge +3

One way to accomplish this is using a modulo operation in a visible to expression and duplicating your report section.

The section you want shaded can have the background color specified in the Style and the visible expression would be =$LineNbr % 2 = 1. The unshaded section would then just need the expression to be =$LineNbr % 2 = 0.

If you don’t want the entire section shaded you could do something similar with panel elements as well.

 

 

Userlevel 7
Badge +11

Hi @arjan 

Here is a previous post which explains above approach. 

Hope this helps,

Regards,

Userlevel 1
Badge

please see the attached example and where it needs to be applied.

i tried what @Neil Cantral suggested, couldnt get it to work.

@vkumar i checked that out before posting this question, not sure if that’s the solution to what i needed.

Userlevel 5
Badge +3

I didn’t check the groupings/variables the first time and had to change the visible expression to =$KitLineNbr % 2 = 1. Below is a picture of the results.

I attached a copy of the out-of-the-box pick ticket report that I modified.

 

 

Userlevel 1
Badge

Thanks @Neil Cantral !

now, how can i avoid duplication?

 

Userlevel 5
Badge +3

Looks like there’s something off with the visible expression. You will need to adjust the formula to fit your report. If this is based on the original pick ticket report the groupKit contains the variable $KitLineNbr and is likely what is needed to get the visible expression to work as intended.

Unshaded section: =$KitLineNbr % 2 = 1 

Shaded section: =$KitLineNbr % 2 = 0

I can provide more specific guidance if you can attach the report file. You can save the report from the report designer by going to File>Save As to save the .rpx file, send it to a compressed (zipped) folder, then attach the .zip.

Userlevel 7
Badge

 Hi @arjan were you able to resolve your issue? Thank you!

Userlevel 7
Badge +4

@arjan Typically duplicating results has to do with the relations of the report and there could be a key linking field missing from the relations or there is an extra relation which needs to be removed.

I see the age of this post is older, but did you end up solving the issue?

Userlevel 1

Thank you to all who helped - this is now setup at my client and working like a dream.  

Userlevel 4
Badge

Group,

I want to add to this conversation.  Above is great information, but I have some questions around this.  The report that I am working on is GL633500 from out of the box (I believe).

I duplicated a section to create a new highlighted area, but it didn’t move it directly under the original section.  How can I move it so that the new one is right below the original section? 

The red line row is the original section, the blue is the duplicate section.

The visible expression I attempted to use to highlight every other section, but it didn’t work.  So that is one area I could use some help with. Is there something we need to add to the filters in order to use like LineNbr in that expression?

Below is a screenshot of the report.  This is why I choose PeriodID.

This is what the report looks like when it is run:

 

 

Second question I have is with the visible expression on the original section.  There is already an expression listed there.  What would the best way to write it? (I am still very new to writing code).

 

Thank you in advance for any and all pointers!

 

Reply


About Acumatica ERP system
Acumatica Cloud ERP provides the best business management solution for transforming your company to thrive in the new digital economy. Built on a future-proof platform with open architecture for rapid integrations, scalability, and ease of use, Acumatica delivers unparalleled value to small and midmarket organizations. Connected Business. Delivered.
© 2008 — 2024  Acumatica, Inc. All rights reserved