Forum Discussion
Ms project
Microsoft Project does support IIf and Switch formulas in custom fields, but syntax errors usually occur if the formula is placed in the wrong field type or if quotation marks and separators are mismatched. The key is to ensure you are using these functions in a custom field formula (via Project > Custom Fields > Formula) and that the field type matches the return value (Text, Number, Flag, etc.).
https://support.microsoft.com/en-au/project/project-functions-for-custom-fields-in-project-desktop
Thank you for the response, however I am using the custom fields box using the formula below, but I keep getting errors. Please try on your side and provide an update.
IIf(ProjDateDiff(Start,[Status Date])/480>=Val(ProjDurConv([Baseline Duration],pjDays)),Val(ProjDurConv([Baseline Duration],pjDays)),IIf(DateDiff("d",[Baseline Start],[Status Date])<=0,1/100,ProjDateDiff(Start,[Status Date])/480))