How to send one email if a certain excel column have specific values in it


I want to send an email if a specific excel column has these specific values in it (apple, carrot, banana). I have been using the for each activity, however, that sends me multiple emails if the values are in the column rows more than once. I want to only get one email and not get multiple emails and I keep getting error messages when trying.

Can anyone help me please?

Thanks you!

Hi @Lisa_O,

You can use For each row activity to loop through the datatable.
Within the loop, have an If statement with condition:
Convert.ToString(ColumnName).Trim.toLower.Equals(“apple”) or Convert.ToString(ColumnName).Trim.toLower.Equals(“carrot”) or Convert.ToString(ColumnName).Trim.toLower.Equals(“banana”)

Send the email only for the entries which satisfy the above condition.

Happy coding! :slight_smile:

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.