1

I need help writing an IF statement for a SP calculated column. I have it working right now to display the green indicator, but need to add the clauses for it to display the yellow and red indicators as well.

="<DIV><imgsrc='"&IF(Colour="Green","/_layouts/images/KPIDefault-0.GIF","/_layouts/images/KPIDefault-2.GIF")&"'></DIV>"

The first section (green status) is what is working, the rest needs modification I know. Basically I want to add :

IF Colour="Red" then display "/_layouts/images/KPIDefault-2.GIF"

IF Colour="Yellow" then display "/_layouts/images/KPIDefault-1.GIF"

PLEASE help :)

dave
  • 13
  • 3

1 Answers1

1

Just keep nesting the if statements,

="<DIV><imgsrc='"&IF(Colour="Green","/_layouts/images/KPIDefault-0.GIF",&IF(Colour="Red","/_layouts/images/KPIDefault-2.GIF",&IF(Colour="Yellow","/_layouts/images/KPIDefault-1.GIF")))&"'></DIV>"

The syntax above might not be perfect, but you should get the idea

Dovahkiin
  • 111
  • 3