0

I have a section on our Opportunity that creates a Text formula based on if a box in column A is ticked and the same box in column B is not.

For example, if we request Item 1, we tick the first box, and we don't tick the second box until we receive Item 1. This formula field creates an easy to read list of items that are outstanding, so that I can pull it into email notifications.

The formula has a load of code, but this one is creating a line break when I want it to be NULL.

IF( NOT(ISBLANK(TEXT( Requested_Proof_of_ID__c))) &&  Received_Proof_of_ID__c = true , 
   "", 
   TEXT(Requested_Proof_of_ID__c) + BR()) &

Does anyone have any idea to make it so that when the IF statement equals TRUE, the formula just create a null and not a line break? I only want the line break if the formula equals FALSE and puts the TEXT() in. I've tried different operators and moving the BR(), but I just can't get it to not create the line break.

3
  • 1) checkbox fields can never be blank so the IF condition can be IF (Received_proof_of_Id__c,NULL,TEXT(Requested_Proof_of_Id) & BR()) ; and 2) what does the formula field do after the last & in your OP? – cropredy Nov 24 '20 at 5:45
  • It goes on to do more checking for other fields, so its one formula field that concatenates a bunch of different codes into text. I got help on the Trailblazer forum, and it turns out that my formula was resulting in FALSE no matter what. I rewrote the code to the below and it works :) The "" is not for the checkbox, but for the IF statement. IF((NOT(ISPICKVAL( Requested_Proof_of_ID__c , "" )) && Received_Proof_of_ID__c = false) , TEXT(Requested_Proof_of_ID__c)+ BR(), NULL) & – moxiemason Nov 24 '20 at 6:27
  • well, i did not know that Requested_Proof_of_ID__c was a picklist! oops! Your description implied two checkboxes. I find NULL is best practice vs "" but "" does work too (I like NULL because it is one less thing to worry about when balancing quotes in complex formulas) You can answer your own question – cropredy Nov 24 '20 at 6:32

Your Answer

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

Browse other questions tagged or ask your own question.