I’m working on one of my first UIPath projects and am running into two main issues. My goal is to take success emails and update a spreadsheet with the date and an ‘x’ to show they were successful. My first issue is I want it to find the next open row rather than choosing a static row. The other issue is that the emails are being read new->old and adding the date in that way rather than old->new. Any filter/VB scripting I can add to reverse the order? Attached is an example of the old manual way vs. how it ran via UIPath.
Why does it matter what order the dates get read in? If you must solve that issue, move the emails in question to their own folder and sort the folder in reverse received date order. UiPath will follow that rule. Use a for each email activity to loop through the mail box, then save for later activities to capture your meta data. Then use a For Each Excel Row activity in the outlook activity. Use write cell activities to write the date and the ‘x’ in the current row. The For Each Row activity will automatically stop when there is no data in a row.
Thanks for the response! They are routed to their own folder and I did sort them in reverse received date order, but UIPath still pulled it in the opposite direction. I will have to test out the For Each Excel Row activity. Thanks!
The other question that was asked was how to find and start writing in the first empty row, instead of a static cell. How is that done?
Did you tried with Append range activity? Also to find the first/last row of the excel you can use the Use First/Last row activity.
Use Get outlook mail messages activity, you have an option to sort the results there (orderByDate on the properties.). Check the screenshot below.
So I ended up using Write Cell to a blank TEMP excel sheet and then appending (Append Range) all the data written on TEMP to the existing data table, then removing the rows from TEMP. Seems like a bit of a work around, but it functions.
I do not have “Get Outlook Message” in my version of Studio X. In which version is it available?