cancel
Showing results for 
Search instead for 
Did you mean: 

Conditional Formatting not working

vaibhav_rathore
Participant
0 Kudos

Hi,

I have a scenario where we have to show the quantities coming from status Planned as "Yellow" color and Produced as "Brown" color.

I have the status column which is bringing these 2 lots and because of this i am getting 2 rows for a common ID. For example

ID1 Produced 10 (brown color) Date--April 2020(header of crosstab)

ID1 Planned 18 (yellow color) Date--April 2020 (header of crosstab)

expectation:

ID1 Date--April 2020(header of crosstab) 10 and 18 (in a single row) with 10 highlighted as brown and 18 with yellow.

The business wants this in single line and to remove the duplicates.

Note : the Status column is hidden

tried deleting the status column then the formatting is not working

Please advise the solution.

Thanks

Accepted Solutions (0)

Answers (1)

Answers (1)

DellSC
Active Contributor

Move the status to the columns of your cross-tab under the dates instead of using it in the rows. This should give you two values per date in a single row.

Then try this to format the background color:

If GridLabelAt('MyTable.StatusField', CurrentColumnIndex) = 'Planned' then crYellow
Else if GridLabelAt('MyTable.StatusField', CurrentColumnIndex) = 'Produced then crBrown

Replace "Mytable.StatusField" with the table and name of the field that's providing the status in your data.

-Dell

vaibhav_rathore
Participant
0 Kudos

Hi dell.stinnett-christy ,

I tried doing this and was able to get the single row but now the Month is getting duplicated based on the status column. For example if both status Planned and Produced are having quantities for a same month its giving duplicate months.

Can there be any workaround where this can be avoided and we have only one row and a non repeating months even if there is quantity for the same.

Thank You

DellSC
Active Contributor
0 Kudos

Would you post an image of what you're seeing please?

-Dell

vaibhav_rathore
Participant
0 Kudos

Hi dell.stinnett-christy ,

I achieved in bringing the values in a single row without getting the months duplicated for both the statuses "Planned" and "Produced" but now the colouring is not coming.

Please find the screenshot below.

The row with multivalue will be hidden so it dosent affect the report rest all is coming ok.

Please let me know your thoughts.

Thanks

DellSC
Active Contributor
0 Kudos

How do you know whether the number is planned or produced in your current format?

-Dell

vaibhav_rathore
Participant
0 Kudos

Hi,

The lot status Planned or Produced is now coming in one line along with the figures but the coloring is not appearing against them based on status.

DellSC
Active Contributor
0 Kudos

In the sample you posted, I don't see the status, so I don't see a way to distinguish between planned and produced - how do you know which is which? You have to be able to distinguish between the two in order to set the color.

-Dell