Hello jmac60
The Switch command is fairly straight forward - Switch (condition to
test, result if true, next condition, result if true, next
condition, result if true, etc.
So:
Switch([% Complete]=100,0,
If % Complete = 100 set the value to zero
(NOW()>[Finish]) And ([% Complete]<>100),5
If the current date is later than the finish date and % complete is
not equal to 100, set the value to 5
([SPI]<0.51) And ([SPI]>0),5
If SPI is less than 51% and greater than zero, set the value to 5
[SPI]<0.86) And ([SPI]>0.5),4
If SPI is less than 86% and greater than 50%, set the value to 4
(NOW()<[Finish]) And ([% Complete]>0),3
If the current date is earlier than tha finish and the % complete is
greater than 0, set the value to 3
(NOW()<[Start]) And ([% Complete]<>100),1
If the current date is earlier than the Start date and the %
Complete is not equal to 100, set the value to 1
(NOW()>[Start]) And ([% Complete]=0),2
If the current date is later than the start date and the % complete
equals 0, set the value to 2
(NOW()>[Start]) And ([% Complete]>0),3)
If the current date is later than the start date and the % complete
is greater than 0, set the value to 3
I hope this helps. Let us know how you get along.
Julie
Project MVP
Visit
http://project.mvps.org/ for the FAQs and additional
information about Microsoft Project
jmac60 said:
Can someone decode this? I imported this and it works, but I can't
read it to
understand the parameters and where changes should be made.
Switch([% Complete]=100,0,(NOW()>[Finish]) And ([%
Complete]<>100),5,([SPI]<0.51) And ([SPI]>0),5,([SPI]<0.86) And
([SPI]>0.5),4,(NOW()<[Finish]) And ([%
Complete]>0),3,(NOW()<[Start]) And ([%
Complete]<>100),1,(NOW()>[Start]) And ([%
Complete]=0),2,(NOW()>[Start]) And
([% Complete]>0),3)
Thanks