3

I am trying to create a calculated column where 'Today Date' is another date column. The first two block are working fine till the [Enter time]=2 condition when I add other two it says syntax error.

IF( ([Enter Time]="1")
    ,([Today Date]+365)
    ,(IF(
          ([Enter Time]="2")
          ,([Today Date]+730)
         )
     ),(IF([Enter Time]="3"),([Today Date]+1095))),(IF(([Enter Time]="2"),([Today Date]+1460))))
  • 2
    I reformatted your formula with linebreaks and spaces.. and stopped when you obviously went wrong with the ( ) notation.. Tip: do this in a decent texteditor then copy paste your formula to SP, it will remove all linebreaks and unneeded spaces – Danny '365CSI' Engelman Oct 19 '16 at 9:27
  • 1
    If you use Named-Cells in Excel you can also prepare your Formula in Excel and make it work in Excel first – Danny '365CSI' Engelman Oct 19 '16 at 9:29
5

Try this condition

IF([Enter Time]="1",[Today Date]+365,IF([Enter Time]="2",[Today Date]+730,IF([Enter Time]="3",[Today Date]+1095,IF([Enter Time]="4",[Today Date]+1460))))
2

[Enter Time]="2" is checked twice

IF([Enter Time]="1",[Today Date]+365,IF([Enter Time]="2",[Today Date]+730,IF([Enter Time]="3",[Today Date]+1095,IF([Enter Time]="2",[Today Date]+1460)))

  • Thanks for replying Monica, but I tried it is still throwing error. I believe I missing some brackets but not sure where? – Narinder Chauhan Oct 19 '16 at 9:07

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.