We are celebrating the 10-year anniversary of the Alteryx Community! Learn more and join in on the fun here.
Start Free Trial

Alteryx Designer Desktop Discussions

Find answers, ask questions, and share expertise about Alteryx Designer Desktop and Intelligence Suite.
SOLVED

Conditional Formatting for variable number of columns

Darrie8468
8 - Asteroid

I am being asked to recreate a report that:

  1. Transposes the rows and columns
  2. Shows conditional formatting on all date cells:
  • If the cell date is before today is one color
  • If the cell date is after or equal to today then another color
  • If the cell contents is N/A or TBD then a third color
  • If the cell date is within 7 days of today then a fourth color

I can create column rules for each column in the output, but the number of columns (and their names) may change with each running of the report.

I tried putting the Status in between the Transpose and Cross Tab tools, but I did not know what to do with it.

The workflow has a text input with sample data.

Any help would be greatly appreciated!

5 REPLIES 5
gabrielvilella
14 - Magnetar

If the number of columns keeps changing, you might be able to achieve this if you edit the RAW XML with a macro, but this won't be a simple task. Another idea is to have an Excel template that you just overwrite with new data, but the formatting is there already. In Alteryx, it is always recommended to work with your data in rows to avoid situations like this. Columns should be static and records dynamic. 

Qiu
21 - Polaris
21 - Polaris

@Darrie8468 

There is a detailed disucussion here on how to highlight cells in Table tool.

https://community.alteryx.com/t5/Alteryx-Designer-Discussions/Color-my-cells-conditional-formating/t...

And I am sorry I was not able to fully understand the intended format here. so just my guess.
I also have modified your formula since the String Data can not be compared with a Date Format data.

0413-Darrie8468.PNG0413-Darrie8468-1.PNG

 

Qiu
21 - Polaris
21 - Polaris

@Darrie8468 
I am sorry I think I was mistaken. You have already said in the title.

I get hint from this post and made some modifications.

https://community.alteryx.com/t5/Alteryx-Designer-Discussions/Conditional-Formatting-of-Dynamic-Colu...

0413-Darrie8468-2.PNG

Darrie8468
8 - Asteroid

That is EXACTLY what I needed to move me in the right direction.

Thank you!

Qiu
21 - Polaris
21 - Polaris

@Darrie8468 
Thank you for the feedback and glad to be helpful. 😁

Labels
Top Solution Authors