View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
kami kami is offline
external usenet poster
 
Posts: 6
Default Macro coding using GIF

I created a status report with the following outcomes in MS Excel:

Stat(Column A3) = 0 Not Started (Blue Color)
Stat = 1 On track (Green Color)
Stat =2 Slightly behind (Yellow color)
Stat = 3 Needs Immediate attention (Red Color)

I used the following equation:

=If (A3=0,"BLUE",IF(A3=<=1,"GREEN",IF(A3<=2,"YELLOW", IF A3=3,"RED",""))))

This works fine.

However, Instead of having A3 field colored, I want to use picture that has
the color instead. I tried to use a macro to do just that am having problem.
Here is what I want to similar meaning to the below statement in Macro

=If
(A3=0,"lightblue.gif",IF(A3=<=1,"lightgreen.gif",I F(A3<=2,"lightyellow.gif",
IF A3=3,"lightred.gif",""))))

I would appreciate anybody's assistant. Thank you.