Verify Text in a File: verifytext
The Verify Text In A File function checks whether a specified text exists in a given text file. If the text is found, the function returns true; otherwise, it returns false. The result is stored in the variable defined in the Element Key, allowing it to be used in subsequent automation steps.
Note: Ensure that the file being used is not open during the execution of the Case to avoid errors or conflicts.
Example: Suppose you have a text file named LogFile.txt located in **C:\Logs**. You need to check if the text “Error 404: Not Found” is present in this file.
Steps to Configure
- Add a new step in the automation workflow.
- Select Set a Variable Value from the Action dropdown.
- Enter a variable name in Element Key (e.g., TextFound) to store the result.
- Click on Form, select Functions, and choose VERIFYTEXT function.
- Provide the following parameters:
- File Path: C:\Logs\LogFile.txt
- Text: “Error 404: Not Found”
- Click Save.
Note: While the steps for adding an Action are identical in both views, the display of the steps changes:


Outcome on Execution:
- If the file contains the specified text, the variable defined in the Element Key field, e.g., TextFound will store true.
- If the text is not found, TextFound will store false.
- You can reference this variable in automation using the syntax ${VariableName} (e.g., ${TextFound})