How to create an email with Gmail with info of excel?

Hello I need your help,
I’m trying to create an automation that sends an email via Gmail but place 2 pieces of data that are inside an excel.

How can I do so that in the body of the message these 2 data that are taken directly from the excel are added?

I already have a read range with the excel file and I am using (Use Gmail + Send Email).

Hi @melissag

Read the data from the excel & keep the data table ready. Prepare a html tabular string by infusing dynamic data from the data table in it. Please go through the following resource to know more on this:

Hope this helps,
Best Regards.

Hi @melissag

To add data from an Excel file to the body of an email using UiPath and send it via Gmail, you can follow these steps:

  1. Use the “Excel Application Scope” activity to open the Excel file.
  2. Use the “Read Range” activity to read the data from the Excel file and store it in a DataTable variable.
  3. Create a string variable to hold the message body.
  4. Use a loop (e.g., “For Each Row” activity) to iterate through the rows of the DataTable.
  5. Inside the loop, access the values from the desired columns of each row and append them to the message body variable.
  6. Use the “Send Outlook Mail Message” or “Send SMTP Mail Message” activity to send the email via Gmail, depending on your specific requirements.