Data Extraction and Processing,,

Scenario :

You are given an Excel file with a list of customer details, including names, email addresses, and order details. How would you use UiPath to extract this data and send personalized emails to each customer?

Thanks.

@gantamohan502
Read Range the excel workbook and store it in datatable.
Use for each row in datatable
In that loop Use send Smtp mail message activity and send your Email

@gantamohan502

-Use the Excel Application Scope activity to open the Excel file.
-Use the Read Range activity to read the data into a DataTable.
-Loop through each row in the DataTable using a For Each Row activity.
-Within the loop, use the Send SMTP Mail Message activity (or the appropriate email activity based on the email service) to send personalized emails. Use the values from the DataTable to fill in the email content.
-Handle exceptions and errors using Try Catch activities to ensure the process completes successfully even if some emails fail to send.

Cheers

1 Like

@gantamohan502

  • Read Excel File:

  • Use Excel Application Scope to open the Excel file.

  • Use Read Range to read data into a DataTable (e.g., customerDataTable).

  • Loop Through Each Customer:

  • Use For Each Row to iterate through customerDataTable.

  • Extract Customer Data:

  • Use Assign to extract Name, Email, and OrderDetails from each row.

  • Assign To=“customerName” Value="row(‘Name’).ToString()
    Assign To=“customerEmail” Value="row(‘Email’).ToString()
    Assign To=“orderDetails” Value="row(‘OrderDetails’).ToString()

  • Compose Email:

  • Use Assign to create an email body with personalized content.

  • Send Email:

  • Use Send Outlook Mail Message (or another email activity) to send the email using the extracted data.

Hi @gantamohan502

Follow the below steps,
→ Use Read range workbook activity to read the excel file and store in a datatable called Input_dt.
→ Then use the For each row in datatable activity to iterate the each row in Input_dt.
→ Inside for each insert the Send SMTP Mail Message or Send Outlook Mail Message activity to send the mail to the each customer.

Hope it helps!!

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