RegEx Extract
RegEx Extract is one of the most useful Actions that you can add to your flows. It will allow you to automate the way you work with documents inside your flows.
As a user I want an action that extracts all the emails from a document/string based on RegEx validations and saves them into a list. This action will help me extract from a strings only the values that validates with the RegEx expression and in this scenario I will extract a list of emails that I could use for marketing purposes.
1. Create a new process and give it a name.
2. Drag the Regex Extract action to the canvas and link it to the other actions.
3. Click the Regex Extract action to access its configurations and click the button Regex Configurations.
- <%texttoextractfrom%> - variable that awaits the text to search in, it will ask for the text every time the process is ran (this is an input variable).
- <%regexexpression%> - variable that has the Regex Value saved as Default value. The Regex that looks for email addresses is "([_\.0-9a-zA-Z-]+@([\-0-9a-zA-Z]+\.)+[a-zA-Z]{2,6})".
- <%listofemails%> - the list that will contain all the emails present in the text you entered in the first variable.
If you wish to search the text regardless of case check the Ignore case checkbox.
5. Save and Validate the process.
6. Each time you will run the process you are expected to add the text you wish to check.
7. Because we have created <%listofemails%> of type output, when you click Check instances you will be able to see that the email addresses were saved in the list.