Hi All, Is there an expression to show an upw...

(Malaka Jayawardene) #1

Hi All, Is there an expression to show an upward directed arrow or a downward directed arrow next to a numerical value, if that numerical value exceeds or is less than a certain number? For example, I have a table consisting of columns, each for a blood investigation (eg: Haemoglobin, White cell count, platelets etc.) If the user enters a value in to the numerical text field of Haemoglobin, if it is less than 12, I’m trying to get a “downward directed” arrow shown immediately next to the haemoglobin value, and if the user enters a value over 17, an “upward directed” arrow next to the haemoglobin value. I wrote the following expression to the AppFormula of Haemoglobin (decimal type column), but it didn’t work. =IFS([Haemoglobin]>17,CONCATENATE([Haemoglobin]," ↥"),[Haemoglobin]<12,CONCATENATE([Haemoglobin]," ↧"))

Can someone help me? Thanks!

(Steven Coile) #2

Have you considered a format rule (UX > Format Rules) for this?

(Reza Raoofi) #3

Steve is right; check this out: https://intercom.help/appsheet/ux/format-rules/format-rules-the-essentials

(Malaka Jayawardene) #4

+Steve Coile @RezaRaoofi Thank you very much!

(Malaka Jayawardene) #5

If the table has a lot of columns (many blood investigations), since each blood investigation has its own lower and upper limit, I guess I have to repeat the process multiple times and create individual format rules many a time isn’t it? Because I selected all the columns in one go and wrote an expression

OR([Haemoglobin]<12,[WBC]<3.5,[Platelets]<150,[Na+]<135,[K+]<3.5,[FBS]<65,[ALT]<5,[AST]<6,[Albumin]<35,[Total Protein]<60,[Total Bilirubin]<0.1,[Direct Bilirubin]<0.01,[ALP]<42,[Gamma-GT]<5,[INR]<0.9,[Amylase]<25,[Lipase]<7,[Triglycerides]<70,[Calcium]<1.0,[CEA]<3.5,[CA 19-9]<40,[AFP]<44)

And it made all the columns to be converted to the format rule even if the value is within normal limits.

(Steven Coile) #6

Yes, you’ll need a separate format rule for each column that has a distinct trigger condition. Note that there is an option to copy a format rule that should make your task easier.