Forum Discussion
ChadBrandmire
8 years agoQrew Assistant Captain
Got it! Grrr math
var number CFD = ToDays(ToDate([Calculated Finish Date]) - Today());
var number Dur = [Duration];
var number PC = [% Complete] *100;
var number SD = ToDays(ToDate([Start]) - Today());
var text Red = "#FF3030";
var text Yellow = "yellow";
var text Orange = "#fda302";
If(
$SD < 1 and $CFD < 3 and $Dur < 10 and $PC < 50, $Red,
$SD < 1 and $CFD < 3 and $Dur < 10 and $PC < 70, $Orange,
$SD < 1 and $CFD < 3 and $Dur < 10 and $PC < 85, $Yellow,
$SD < 1 and $CFD < 10 and $Dur < 30 and $PC < 50, $Red,
$SD < 1 and $CFD < 10 and $Dur < 30 and $PC < 70, $Orange,
$SD < 1 and $CFD < 10 and $Dur < 30 and $PC < 85, $Yellow,
$SD < 1 and $CFD < 30 and $Dur < 90 and $PC < 50, $Red,
$SD < 1 and $CFD < 30 and $Dur < 90 and $PC < 70, $Orange,
$SD < 1 and $CFD < 30 and $Dur < 90 and $PC < 85, $Yellow,
$SD < 1 and $CFD < 35 and $Dur >90 and $PC < 50, $Red,
$SD < 1 and $CFD < 35 and $Dur > 90 and $PC < 70, $Orange,
$SD < 1 and $CFD < 35 and $Dur > 90 and $PC < 85, $Yellow)
var number CFD = ToDays(ToDate([Calculated Finish Date]) - Today());
var number Dur = [Duration];
var number PC = [% Complete] *100;
var number SD = ToDays(ToDate([Start]) - Today());
var text Red = "#FF3030";
var text Yellow = "yellow";
var text Orange = "#fda302";
If(
$SD < 1 and $CFD < 3 and $Dur < 10 and $PC < 50, $Red,
$SD < 1 and $CFD < 3 and $Dur < 10 and $PC < 70, $Orange,
$SD < 1 and $CFD < 3 and $Dur < 10 and $PC < 85, $Yellow,
$SD < 1 and $CFD < 10 and $Dur < 30 and $PC < 50, $Red,
$SD < 1 and $CFD < 10 and $Dur < 30 and $PC < 70, $Orange,
$SD < 1 and $CFD < 10 and $Dur < 30 and $PC < 85, $Yellow,
$SD < 1 and $CFD < 30 and $Dur < 90 and $PC < 50, $Red,
$SD < 1 and $CFD < 30 and $Dur < 90 and $PC < 70, $Orange,
$SD < 1 and $CFD < 30 and $Dur < 90 and $PC < 85, $Yellow,
$SD < 1 and $CFD < 35 and $Dur >90 and $PC < 50, $Red,
$SD < 1 and $CFD < 35 and $Dur > 90 and $PC < 70, $Orange,
$SD < 1 and $CFD < 35 and $Dur > 90 and $PC < 85, $Yellow)