Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi All
I have 2 table , each table have it correct color and wrong color :-
Table 1 Sales color correct. But Payroll Exp color wrong.
Table 2 Sales color Wrong. But Payroll Exp color Corect.
I aware the issue is cause by the Amount , if Amount is positive it will
Now For Table 3 , I Add a field = PLUS,display Green and if Amount is negative it will display Red.
Because system does not know the Amount is sales or Expense.
In order to let the system know the amount is sales or Expense , I add a new field = PLUS
So i hope that the color will display as below behavious :-
When PLUS=P if Amount is positive make back ground color Green and Amount negative make color Red
When PLUS=N if Amount is positive make back ground color Red and Amount negative make color Green.
Above is what i want , but i don't know how to start. Hope some one can advise me.
Paul
Dear Paul,
Please see table 1 in the attached file. I have used the following syntax in your variance expression:
if(PLUS = 'P' and Column(3) >0 , Green(),
If(PLUS = 'N' and Column(3) < 0 , Green(), Red()))
This seems to be giving you the output you were after.
Regards
R
My QV doc explain in more detail with graphic.
Hi Paul,
It is very simple, instead of using Visual Cues, click on the little plus sign next to the expression and double click 'Background Color'.
Enter your IF statements, with results of LightRed() and LightGreen() accordingly...
Regards.
Dear Paul,
Please see table 1 in the attached file. I have used the following syntax in your variance expression:
if(PLUS = 'P' and Column(3) >0 , Green(),
If(PLUS = 'N' and Column(3) < 0 , Green(), Red()))
This seems to be giving you the output you were after.
Regards
R
Hi Martyn
Thank you vey much , you got the point , so i try to create expression as below , but it does not work. Hope you can advise me.
if(
PLUS='P',
(
COLUMN(2)-COLUMN(1))/COLUMN(1)>0,LightRed()
),
(
COLUMN(2)-COLUMN(1))/COLUMN(1)<0,LightGreen()
)
if(
PLUS='N',
(
COLUMN(2)-COLUMN(1))/COLUMN(1)>0,LightGreen()
),
(
COLUMN(2)-COLUMN(1))/COLUMN(1)<0,LightRed()
)
Hi Rahul
Thank you your expression working fine.
if(PLUS = 'P' and Column(3) <0 , lightGreen(),
If(PLUS = 'N' and Column(3) > 0 , lightGreen(), lightRed()))
Paul
Hi Paul,
Sorry, was running a long script, you had some syntax errors with your nested IFs.
Did you find my first reply "Helpful"?
Marty.
Hi Martyn
Now i manage to solve it , the approach is same as your first reply. so i confirm your first reply is right approach. Rahul give me very simplify expression and working fine now.
Paul
Hi Paul,
In that case, would you be happy to mark my reply as Helpful?
Regards.
Hi Martyn
Just mark very helpful.
Thank you very much. As this issue is existed more then 1 yr.