I am trying to create a system in the admin portal to set the default legend code with a monstrous if statement that would determine if the description contained "CLAY", then check if it contained "Sandy" and "Silty" and "Gravelly", etc. Is it possible to determine whether a string contains a certain substring?
Something like this: Is there an Expression that will test for specific text ? - gINT Forum - OpenGround | gINT | Keynetix - Bentley Communities however this is a gINT formula, not an admin portal one, and attempting to just change the symbols to correlate with those of the admin portal does nothing.
Any help appreciated!
Hi Joshua, you can use the find() function in Admin Portal to search if a string contains a substring. I believe find() is case sensitive.
Here's a simple example: if(find('COBBLES',[StratumDetails.PrimarySoilName],0)>=0,'cobbles','not cobbles').