I came across the term Robotic Process Automation (RPA) , when suddenly in 2019 many of my job alerts were all about "RPA Engineer Required!". Being in the robotics space, it came as a curiosity. However, I quickly found that it has nothing to do with robotics.
RPA is a quicker and more understandable methodology to create programs that do boring tasks for us. A more refined definition will be,
Robotic Process Automation (RPA) is the use of computer programs to perform repetitive and labor-intensive tasks.
Repetitive tasks could be like sending emails , verifying receipts , scraping data from a website . These can take an average person several minutes to several hours. If such tasks can be handed over to robots (each automated program is basically a robot), then employees can make more time to work on creative ideas. The things that humans are good at.
This article describes an RPA use case, with my personal experience. I'll first explain my motivation with RPA, then we'll see how we can solve an automated emailing issue that involves reading data from Google Sheets.
I decided to give RPA a shot while I was working for Addressya. We had a shared Google Sheet where everyone put in the time they will be working the next week. Because of flexible hours, it was important everyone knows when are the colleagues working. However, most employees forget to report their times. Therefore, one of our colleagues had to send a reminder to all the defaulters. This seemed like a good opportunity to try something new. I decided to read the Google Sheet, find the defaulted person and send them an email.
I choose UiPath , an RPA platform development platform, because of their community edition that can be used for free. Moreover, the program can be reused on different machines. UiPath has these visual snippets or components called Activities. To use an activity, all you need to do is drag and drop in the main workplace and reorder activities according to needs.
I saw a few tutorials on the UiPath Academy and decided to get right into it. The first step was to read data through Google Sheets. The following steps are for recreating the application, you can skip if you like.
If all the information is correct then the data should be read correctly. You can try writing the DataTable locally using the Write Range activity from Excel, this should create an Excel file on your PC.
In order to make the data fetched from Google Sheets useful, I did some processing using For Each, Assign and If activities. The purpose was to see if any employee forgot to fill their expected attendance and to extract their email address. It was pretty easy to understand and use, except for one operation, i.e. looping over a DataTable. Therefore, I will just discuss that.
I created a nested loop situation, with the outer loop reading a row in the DataTable. In order to read the row by column by index, I used the second loop over a list of indexes from 0 to the length of the row.
Then, I used the assign activity to read each column of that row. An If activity checked if the cell was empty. If yes, then I stored the name of that person.
Now that I had the name of the defaulter, it's time to send them an Email. The Send SMTP Mail Message activity is pretty simple to use. All you need is your port and server address of your the email account you want to send it from. In my case, this was Gmail i.e. 587 and smtp.gmail.com respectively.
One issue was that the email body did not incorporate spaces. I had to use the NewLine property in C#. Which wasn't easy to find since I am not that familiar with C#.
I really enjoyed how it worked. Once a robot was deployed it took a click to fire it up. UiPath gives a second application called UiPath Robots to invoke a specific robot.
I added a little pop-up at the start to add the Google Sheet name so that my colleague sending the reminders shouldn't be concerned about the code. If we add the sheet name then emails will automatically be sent to all defaulting employees.
It really piqued my interest and I wanted to know how people are using it these days. The response I have so far from SMEs is the concern about privacy and usage of sensitive data. Moreover, some startups have found it not at all convenient. For example in Sweden, we use BankId as a way to confirm payment transfers. Which requires a passcode to log in. The problem is that if this passcode ends up in the wrong hands then it could be catastrophic for the company, therefore they refrain on giving complete control to a machine. On the other hand, RPA can involve human intervention in such sensitive matters (like I did with the initial pop-up), but this increases the inconvenience. Hence, RPA developers should start working on solutions to handle sensitive data.
To close this, I would say RPA is a useful tool of the future. We are seeing the banking sector adopting it pretty quickly . It's not far that other sectors will see the potential soon enough. The whole process is fun, I guess with a little practice anyone with basic programming skills can get used to it. UiPath is clean and convenient.
For those who think that RPA is coming for their jobs, well yes and no. RPA is a tool to enhance your productivity in the workspace and not replace you. You can forget about sending boring emails and instead focus on building value for the company. In that case, you are worth more than a thousand RPA robots.
 van der Aalst, W. M., Bichler, M., & Heinzl, A. (2018). Robotic process automation.
 Ionescu, V. (n.d.). Send Email Automation. Retrieved May 21, 2019, from https://www.uipath.com/kb-articles/send-email-automation
 Rossum and UiPath: Invoice extraction in 15 minutes (source code provided) - Cognitive Data Capture, Machine Learning, AI. (2019, May 15). Retrieved May 21, 2019, from https://rossum.ai/blog/rossum-and-uipath-invoice-extraction-in-15-minutes-source-code-provided/
 Badita, M. (n.d.). Web Data Extraction. Retrieved May 21, 2019, from https://www.uipath.com/kb-articles/web-data-extraction
 Tripathi, A. M. (2018). Learning Robotic Process Automation: Create Software robots and automate business processes with the leading RPA tool–UiPath. Packt Publishing Ltd.
 “Robotics in Banking with 4 RPA Use Case Examples | The Lab.” The Lab Consulting, 9 Apr. 2019, thelabconsulting.com/robotics-in-banking-with-4-rpa-use-case-examples/.