Finding specific words from selection

I'm struggling to get a good snippet to grab specific words from a selection. I currently have this below snippet grabbing my "Install Notes" from a construction job. Below that I have the example of the notes the selection tool is selecting. Would love help troubleshooting! I've tried asking the AI for a few different solutions to no avail

{install_notes={site: text; select=ifneeded; selector=[field-label="Install\ Notes"] .test-id__field-value; page=https://renewalbyandersen.lightning.force.com/*}}{if: contains(install_notes, "break out")}Stucco Breakout :triangular_flag_on_post:{endif}{if: contains(install_notes, "breakout,")}Stucco Breakout :triangular_flag_on_post:{endif}{if: contains(install_notes, "scaffolding,")}CONFIRM SCAFFOLDING :building_construction:{endif}

INSTALL NOTES
Need Scaffolding for High windows in Living Room interior + exterior.
5 person crew + 2 person crew - 3 days (Does not meet RPI)
REMOVE ALL WINDOW FRAMES AND DOOR FRAME.
BREAK OUT STUCCO AROUND OPENINGS - INSTALL
ALL ITEMS WITH A NAIL FIN. APPLY
MULL STOP FLASHING AND APPLY STUCCO
LATH TO FRAMES, RE STUCCO ANd TEXTURE
TO MATCH - HOMEOWNER RESPONSIBLE
FOR PAINTING OF NEW STUCCO.

Hey Nathan! Happy to help troubleshoot this with you. I was able to get your snippet working by doing the following:

  1. Your If/Else conditions are looking for "breakout" and "break out", but not "BREAK OUT" which is how you have it typed in the install notes. These are case sensitive, so that is why it isn't picking it up.
  2. You can make a slight adjustment to the If/Else field to solve for this. You'll need to use a lower command, but essentially it just needs to look like what I have created below:
    Screenshot 2024-04-17 at 3.51.29 PM
  3. All I did was click on the if/else command and added the lower command with "install_notes" inside of the parentheses.

You can see me do it live in this video that I created for you here!

2 Likes

You are the MVP Oliver, thanks for the detailed rundown of how you did it. This was super helpful in teaching myself how to to do these in the future.

2 Likes