PS Suite: Checking for Smoking Status Using an eForm or Tablet Rule

The smoking status is drawn from the "RISKS" field in PS Suite, as text. The content of "RISKS" is available in the keyword "@ptCpp.soc" (if you are curious: "soc" stands for social history).

If you would like to display the smoking status, you can use the "@ptCpp.soc"" keyword in one of the following formulas:

To check if someone is a current smoker:
ScriptUtil.getKeyword("@ptCpp.soc").indexOf("current smoker") >= 0
Copy Formula
To check if someone is an ex-smoker:
ScriptUtil.getKeyword("@ptCpp.soc").indexOf("ex-smoker") >= 0
Copy Formula
To check if someone has never smoked:
ScriptUtil.getKeyword("@ptCpp.soc").indexOf("never smoked") >= 0
Copy Formula


Have more questions? Submit a request