UiPath Activities

The UiPath Activities Guide

Forward Outlook Email

UiPath.Mail.Activities.Business.ForwardMailX

Forwards the specified Outlook email. Should be used for the currently selected email, or while iterating through a list of emails. This activity must be added inside a Use Outlook Account activity.

Configuring the Activity

In the Body of the Activity

  • Email - Click Plus plus button on the right side of the field and then, from the menu, select the email to forward. When the activity is inside a For Each Email activity, select CurrentMail to indicate the current mail in the iteration. Otherwise, select Selected Mail to use the message that is selected in Outlook when the project is executed. Alternatively, you can select Open in Advanced Editor and enter a VB expression.
  • Add To recipients - Click Plus plus button on the right side of the field, and then use one of the options in the menu to select where to forward the email:
    • Data from the Project Notebook, a parent Excel file or Outlook account. For example, you can select a cell in an Excel file that contains email addresses separated by semicolon (;) to add multiple recipients, or use the email addresses from the To field of the email selected in Outlook when the project is executed.
    • Use Saved Value - Use data in the form of a list of email addresses that you previously saved for later use in the project.
    • Text - Enter one or more email addresses separated by semicolon (;) in the Text Builder.
    • Ask when run - Prompt for the recipients when the project is executed.
    • Open in Advanced Editor - Enter a VB expression.
  • Add Cc recipients - Click Plus plus button on the right side of the field, and then use one of the options in the menu to select the secondary recipients of the email:
    • Data from the Project Notebook, a parent Excel file or Outlook account. For example, you can select a cell in Excel with email addresses separated by semicolon (;) to add multiple recipients, or use the email addresses from the Cc field of the email selected in Outlook when the project is executed.
    • Use Saved Value - Use data in the form of a list of email addresses that you previously saved for later use in the project.
    • Text - Enter one or more email addresses separated by semicolon (;) in the Text Builder.
    • Ask when run - Prompt for the recipients when the project is executed.
    • Open in Advanced Editor - Enter a VB expression.
  • New subject - Optionally, you can add a new subject for the email. If a new subject is not provided, the default Outlook subject for forwarded emails is used. Click Plus plus button on the right side of the field and then use one of the options in the menu to add a subject for the email:
    • Data from the Project Notebook, a parent Excel file or Outlook account. For example, you can select a cell in an Excel file, or you can use the subject of the of the email selected in Outlook when the project is executed.
    • Use Saved Value - Use data that you previously saved for later use in the project.
    • Text - Enter a subject in the Text Builder.
    • Ask when run - Prompt for the subject when the project is executed.
    • Open in Advanced Editor - Enter a VB expression.
  • Body - You can add a plain text body or select a Word document to add the file in the email body.
    • If you select Text, click Plus plus button on the right side of the field, and then select one of the options from the menu to add the text for the body of the email:
      • Data from the Project Notebook, a parent Excel file or Outlook account.
      • Use Saved Value - Use data that you previously saved for later use in the project.
      • Text - Enter the body text in the Text Builder.
      • Ask when run - Prompt for the body text when the project is executed.
      • Open in Advanced Editor - Enter a VB expression.
    • If you select Use Word Document, indicate a Word document with tables, images. text formatting to add in the body. The email body is formatted as HTML.
      Click Browse browse files next to the field, and then browse to a Word file and select it. Alternatively, you can indicate the path to a Word file by selecting an option from the Plus plus button menu on the right side of the field:
      • Data from the Project Notebook, a parent Excel file or Outlook account. For example, you can select a cell in an Excel file that contains a path.
      • Use Saved Value - Use data in the form of a file path that you previously saved for later use in the project.
      • Text - Enter a path in the Text Builder.
      • Ask when run - Prompt for the path when the project is executed.
      • Open in Advanced Editor - Enter a VB expression.
  • Save as draft - If selected, the email is saved in the Outlook Drafts folder instead of being sent directly to the selected recipients. This gives you a chance to check the email in Outlook before sending it. This option is selected by default.
  • Attachments - Select Files to attach individual files or Folder to attach all the files in a folder.
    To select the file or folder, click Browse browse files next to the field, and then browse to the file or folder and select it. Alternatively, you can indicate a file or folder path by selecting an option from the Plus plus button menu on the right side of the field:
    • Data from the Project Notebook, a parent Excel file or Outlook account. For example, you can select a cell in an Excel file that contains a path.
    • Use Saved Value - Use data in the form of a path that you previously saved for later use in the project.
    • Text - Enter a path in the Text Builder. You can combine text with a formula from an Excel file cell, for example to add a date to the file name using formulas in the Project Notebook.
    • Ask when run - Prompt for the path when the project is executed.
    • Open in Advanced Editor - Enter a VB expression.

In the Properties Panel

Common

  • DisplayName - The name displayed for the activity in the Designer panel.

Email

  • Body - The plain text body of the email, if Use document as body is not selected.
  • Body document path - The path to the Word document to use as the body of the email, if Use document as body is selected.
  • New subject - See New subject in the body of the activity.

Input

Misc

  • Private - If selected, the data used in the activity is not logged by StudioX.

Options

  • MaxDocumentBodySizeMB - The maximum size (in MB) a Word document can have to be used as the email body. The default value is 2MB.
  • Save as draft - See Save as draft in the body of the activity.
  • Use document as body - If selected, it indicates a Word document is added as the email body. The document is defined in the Body document path field.

Receiver

Sender

  • Sent on behalf of - Another user with access to the mailbox on behalf of whom to send the message. Indicate the user in a similar way to how you indicate a To or Cc recipient.

Updated 25 days ago


Forward Outlook Email


Suggested Edits are limited on API Reference Pages

You can only suggest edits to Markdown body content, but not to the API spec.