i have to make a process which send mail based on file name and name in excel. I get the file name then from datatable which has the company name and emails to which I have to send an email with attachement (the file in folder). In folder there are also files for other companies that I have to send so I need to compare file name and the name in excel and then send file to their mail (written and read from data excel table).
Please follow the below steps and let us know if you face any issues.
Use work book read range activity and store your data.xlsx into EmailsDetailsDT.
Use For each and assign the Data table EmailsDetailsDT for loop the Names and email id one by one.
Store some variables for further usage like below for each iteration.
Name = CurrentRow(“NAME”).tostring
Email1 = CurrentRow(“EMAIL”).tostring
Email2 = CurrentRow(“EMAIL2”).tostring
Now the inside the for each row loop along with the above variables we have to maintain the below logic to get the exact file path by suing NAME variable.