Trying to create a text formula field that returns certain texts based on combinations of possible values in other fields. Every time I update the syntax, I get an error message either about parameters, parentheses or commas. Any insight??
IF(TEXT(Next_Refinement_Kit_Action__c,"AWAIT Refinement PHOTOS"),"Photo Stage",
IF(OR(
ISPICKVAL(Next_Refinement_Action__c,"PATIENT REQUESTS REFINEMENTS"),
ISPICKVAL(Next_Refinement_Action__c,"SEND REFINEMENT PHOTOS TO ORTHO")),"Photo Stage",
IF(OR(
TEXT(Next_Refinement_Kit_Action__c,"AWAIT Refinement KIT"),
TEXT(Next_Refinement_Kit_Action__c,"AWAIT Refinement Redo KIT"),
TEXT(Next_Refinement_Kit_Action__c,"GRADE Refinement PVS"),
TEXT(Next_Refinement_Kit_Action__c,"REQUEST Refinement REDO KIT"),
TEXT(Next_Refinement_Kit_Action__c,"SCAN KIT"),
TEXT(Next_Refinement_Kit_Action__c,"SEND STLS TO CC")))))),"PVS/Scan Stage",
IF(OR(
ISPICKVAL(Next_Refinement_Action__c,"AWAIT REFINEMENT PVS"),
ISPICKVAL(Next_Refinement_Action__c,"SCAN REFINEMENT PVS"),
ISPICKVAL(Next_Refinement_Action__c,"SEND REFINEMENT TO MESH/SCULPT"),
ISPICKVAL(Next_Refinement_Action__c,"AWAIT REFINEMENT MESH/SCULPT"),
ISPICKVAL(Next_Refinement_Action__c,"SEND REFINEMENT STLS TO CC"),
ISPICKVAL(Next_Refinement_Action__c,"REQUEST Refinement REDO KIT"),
ISPICKVAL(Next_Refinement_Action__c,"AWAIT Refinement Redo KIT"),
ISPICKVAL(Next_Refinement_Action__c,"SEND Refinement STLS TO FC"))))))),"PVS/Scan Stage",
IF(TEXT(Next_Refinement_Kit_Action__c,"AWAIT Refinement TP"),"TP Stage",
IF(OR(
ISPICKVAL(Next_Refinement_Action__c,"AWAIT REFINEMENT TP"),
ISPICKVAL(Next_Refinement_Action__c,"SEND REFINEMENT TP TO ORTHO"),
ISPICKVAL(Next_Refinement_Action__c,"SEND REFINEMENT TP TO CUSTOMER"))),"TP Stage",
IF(
ISPICKVAL(Last_Refinement_Comm__c,"Customer approved TP"),"Production/Active",
IF(OR(
ISPICKVAL(Next_Refinement_Action__c,"MANUFACTURE REFINEMENT ALIGNERS"),
ISPICKVAL(Next_Refinement_Action__c,"REFINEMENT ALIGNERS SENT TO CUSTOMER",
ISPICKVAL(Next_Refinement_Action__c,"ACTIVE REFINEMENTS CUSTOMER"))),"Production/Active",
IF(
TEXT(Next_Refinement_Kit_Action__c,"AWAIT Refinement TP"),"Production/Active"
)))))))))
ISPICKVAL(Next_Refinement_Action__c,"SEND Refinement STLS TO FC"))))))),"PVS/Scan Stage",
, the parentheses are unbalanced. Derek's suggestion may help you figure out what you meant to do here. Remember thatIF()
always takes three parameters.\n
as a new line (i.e. hit the "enter"/"return" key), and\t
as a tab (or 4 spaces), then the first few lines of your formula would look likeIF( \n \tTEXT(Next_Refinement_Kit_Action__c,"AWAIT Refinement PHOTOS"), \n \t "Photo Stage", \n \t IF( \n \t \t OR( \n \t \t \t ISPICKVAL( ...