OUTLOOK Find an e-mail function

The OUTLOOK Find an e-mail function in RPA.

Help Centre › Building Processes

This article describes the RPA Outlook functionality to find e-mails matching search criteria.

For a full list of available functions, please read OUTLOOK functions.


Description

The OUTLOOK Find an e-mail function allows you to search a mail folder for e-mails by subject, sender, recipients, body, date range, read status, importance and attachments. It returns a list of the matching e-mails.


Setting it up

To use the OUTLOOK Find an e-mail function, follow these instructions:

{{popups:rpas/add:action=outlook-find}}

Once on a process map:

  1. Navigate to the process where you would like to add the OUTLOOK Find an e-mail function
  2. Click on the green button's drop-down (right side of the green button labelled "Process")
  3. On the menu that appears, click on the "+ Activity" item
  4. From here you can select the OUTLOOK Find an e-mail option
  5. Click "Add" once you are done

Input parameters

ParameterRequiredTypeDefaultDescription
FolderNoTextCurrent folder, then InboxThe mail folder to search, e.g. Inbox or Archive/2026
Subject containsNoText-Only emails whose subject contains this text
From containsNoText-Only emails whose sender name or address contains this text
Received fromNoText-Only emails received on or after this date (YYYY-MM-DD)
Received toNoText-Only emails received on or before this date (YYYY-MM-DD)
Max resultsNoNumber50The most emails to return
VariableYesText-The variable to store the matching emails in
Has attachments onlyNoSwitchOffOnly emails that have attachments
Unread onlyNoSwitchOffOnly emails that are still unread
To containsNoText-Only emails whose To addresses contain this text
Cc containsNoText-Only emails whose Cc addresses contain this text
Body containsNoText-Only emails whose message text contains this text
ImportanceNoSelect-Only emails with this importance: High, Normal or Low
Sort byNoSelectLatestLatest or oldest received first
Advanced filter (DASL)NoText-For power users: a raw Outlook filter, combined with the fields above
Mark as readNoSwitchOffMark each email found as read

Output variables

VariableTypeDescription
VariableListThe matching emails, newest first unless you sort otherwise. Each email has fields such as sender, subject and body – see Email fields. Read the first one's sender as {emails::0::sender} if the variable is emails.

Errors

ErrorDescription
Outlook not openOutlook is not running
Folder not foundThe specified folder does not exist

Tips

  • Combine multiple filters to narrow your search results
  • Use Sort by to get the latest or oldest emails first
  • Set Max results to avoid reading too many emails
  • To check who sent an email, use the sender field (the address), not from

Related functions

See it working on your own data

Everything documented here ships with the platform – try the document tools free, or go live in 7 days.