Multiple IF functions within one equation?

I am trying to use multiple IF functions within one equation and getting an unparseable error!

This function should return differently if a program is U12 type "Active", if it is not "Active", is "Virtual" and not "Youth and Adult", if it is "Virtual" and "Youth and Adult" and if otherwise (not youth and adult, not virtual and not type "Active")

The equation shows up in full colour when I put it into a cell, so the basic syntax is there, but I can't figure out why it isn't working. Are my parantheses in the right place?


=IF([U12 In-Person Program Type]@row = "Active", ([Facility Name]@row+" "+"Active/Multisport" + " " +[Program Day of Week]@row +" " + [Season]@row),(IF(AND([Virtual]@row=true, [Youth & Adult Program]@row=false),[Virtual Program Type]@row + " Virtual Program" + [Program Day of Week]@row + " " + [Season]@row),(IF(AND([Virtual]@row=true,[Youth & Adult Program]@row=true),"N/A",([Facility Name]@row + " " + [U12 In-Person Program Type]@row + " " + [Program Day of Week]@row +" " + [Season]@row)))))



Answers

  • Mike TV
    Mike TV ✭✭✭✭✭✭

    @CAN Program Team

    =IF([U12 In-Person Program Type]@row = "Active", [Facility Name]@row+" "+"Active/Multisport" + " " +[Program Day of Week]@row +" " + [Season]@row, IF(AND([Virtual]@row=true, [Youth & Adult Program]@row=false), [Virtual Program Type]@row + " Virtual Program" + [Program Day of Week]@row + " " + [Season]@row, IF(AND([Virtual]@row=true, [Youth & Adult Program]@row=true),"N/A", [Facility Name]@row + " " + [U12 In-Person Program Type]@row + " " + [Program Day of Week]@row +" " + [Season]@row

    I think these changes may work for you.

Help Article Resources

Want to practice working with formulas directly in Smartsheet?

Check out the Formula Handbook template!