custom field formulas returning incorrect values

L

LJI

I'm trying to create a custom field to return a graphical indicator RED/GREEN
depending on whehter the Finish Varaince is greater than, or less than 10days
from Baseline Plan.

"On_Task" is Green (< 10) "Late" is Red (>=10)
Formula seems to returns Green ONLY if variance is Zero or Negative value?

IIf([Finish Variance]>=10,"Late",(IIf([Finish Variance]<10,"On-Task","")))
 
J

Jan De Messemaeker

Hi,

I'm neither a big user nor a fan of formulas but what's wrong with the much
simpler
IIf([Finish Variance]>=10,"Late","On-Task")

HTH
 
J

John M.

Three quick things, although I'm not sure either of them would be the reason
why you always show "green."

1. It may be worth adding an initial check into your formula that a
baseline has been saved.
2. You may want to divide the finish variance by 480 to convert minutes to
a typical 8 hour day
3. You may want to double check whether you are using a hyphen or an
underscore consistently for "On_Task"

This could bring your formula to be something like the following:

Switch([Baseline Start]=ProjDateValue("NA"),"No baseline",[Finish
Variance]/480>10,"Late",[Finish Variance]/480<=10,"On_Task")

John M.
 
C

Christine Flora

All replies have been good ones, but I would like to add...

Make sure you save and republish all of your plans after adding this,
otherwise you could end up with errors being reported when there aren't any.

Regards,
Christine Flora
SpaceDev, Inc.

"We make space happen!"
 
L

LJI

Thanks for your help. I was staring at the thing so long, the hyphen looked
like an underscore. The no baseline idea, was a good one as well.

Appreciate the help.

John M. said:
Three quick things, although I'm not sure either of them would be the reason
why you always show "green."

1. It may be worth adding an initial check into your formula that a
baseline has been saved.
2. You may want to divide the finish variance by 480 to convert minutes to
a typical 8 hour day
3. You may want to double check whether you are using a hyphen or an
underscore consistently for "On_Task"

This could bring your formula to be something like the following:

Switch([Baseline Start]=ProjDateValue("NA"),"No baseline",[Finish
Variance]/480>10,"Late",[Finish Variance]/480<=10,"On_Task")

John M.

LJI said:
I'm trying to create a custom field to return a graphical indicator
RED/GREEN
depending on whehter the Finish Varaince is greater than, or less than
10days
from Baseline Plan.

"On_Task" is Green (< 10) "Late" is Red (>=10)
Formula seems to returns Green ONLY if variance is Zero or Negative value?

IIf([Finish Variance]>=10,"Late",(IIf([Finish Variance]<10,"On-Task","")))
 
L

LJI

Jan,
I tried the below suggestion as well, but I think the problem
was that I was using the Hyphen and the Underscore interchagabley!

Dumb mis-stake on my part, I guess I was starring at the thing so long
it just looked right!

Jan De Messemaeker said:
Hi,

I'm neither a big user nor a fan of formulas but what's wrong with the much
simpler
IIf([Finish Variance]>=10,"Late","On-Task")

HTH
--
Jan De Messemaeker, Microsoft Project Most Valuable Professional
http://users.online.be/prom-ade/
For FAQs: http://www.mvps.org/project/faqs.htm
LJI said:
I'm trying to create a custom field to return a graphical indicator RED/GREEN
depending on whehter the Finish Varaince is greater than, or less than 10days
from Baseline Plan.

"On_Task" is Green (< 10) "Late" is Red (>=10)
Formula seems to returns Green ONLY if variance is Zero or Negative value?

IIf([Finish Variance]>=10,"Late",(IIf([Finish Variance]<10,"On-Task","")))
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top