Learning UiPath RPA (Robotic Process Automation)
Macro Tools
Following on from Macro productivity tools using AlternativeTo I came across:
SikuliX automates anything you see on the screen of your desktop computer running Windows, Mac or some Linux/Unix. It uses image recognition powered by OpenCV to identify and control GUI components. This is handy in cases when there is no easy access to a GUI’s internals or the source code of the application or web page you want to act on.
This is a visual automation tool and I watched a few tutorials. I was quite taken by it in its visual process by screen capture.
AutoIt is a freeware BASIC-like scripting language designed for automating the Windows GUI and general scripting. It uses a combination of simulated keystrokes, mouse movement and window/control manipulation in order to automate tasks in a way not possible or reliable with other languages (e.g. VBScript and SendKeys). AutoIt is also very small, self-contained and will run on all versions of Windows out-of-the-box with no annoying “runtimes” required!
AutoIt was initially designed for PC “roll out” situations to reliably automate and configure thousands of PCs. Over time it has become a powerful language that supports complex expressions, user functions, loops and everything else that veteran scripters would expect.
This is a pretty cool tool, more powerful than Sikuli I think, you can also create executable files to run it. That seems pretty handy as you can share it with others. Also, the fact that IT people use it to setup computers means that it 1/must be reasonably powerful, 2/Must be quite versatile 3/ Be robust.
Robotic Process Automation
But following on from those I also came across UiPath, that has a community edition that seems quite grunty.
Robotic Process Automation Software. Automate rule based business processes. Train and design robots that drive the UI like a human. Robotic Process Automation is an automation performed by a computer (software robot) to drive existing application software in the same way a user does.
After viewing a couple of videos on this tool I was quite wowed with it. It seems to have some good integration with Excel & you can also link to DataBases. These are the tools I am using with the Facility Management Data Extraction process I am exploring so I will try and explore using the Community Edition to see if it meets my needs.
I came across this set of tutorials on YouTube that take you through some of the steps like connecting to a Database:
Idea for testing
My idea is to automate extracting information from a 3D PDF building model file to a CSV file, then take that data into my Excel Macro and filter it for room data and other stuff.
The idea being that I can extract multiple files and populate an Excel worksheet or Database with Facility Management information. So someone just starts a Robot, chooses either a folder or specific files and gets the formatted data at the other end. No need to know anything about the process, justt open a 3D PDF and get the formatted file.
This is broken down into a number of steps:
1. Open Adobe PDF and open a model file.
2. Select all the model and extract model tree to CSV file then close down Adobe Reader. (You could open lots of 3d pdf files and do them in an iterative process.
3. Then open the excel macro sheet, open the csv file and get say, room data from the specified file.
Then export that sheet to a separate workbook. This could then be uploaded to a Database (although there are other routes (From Revit to Database with RTV reporter pro) to get validated data into a database for these assets.
Process
First of all, there is a “community” version of the software that you can request. It doesn’t like gmail or hotmail so you need a business email for doing it. I used my Dataiknow.info email to obtain the link to download the software.
Once installed you have to create a project.
Iteration 1.
My first objective after watching a couple of videos was to:
- Open Adobe Acrobat
- Open a specific 3D PDF file in Acrobat which contained FM Metadata
- Export the Model Tree Metadata to a CSV file and over write the existing “default” export file called Untitled.csv.
That only took me a day to do! A bit of a learning curve, but I finally got there. After getting the basic operation to work I need to change the specific pdf file name to a variable with a selector pop-up box or list, so that it can open up different files and do the extraction to csv files. I’ll also have to look at a method to name the csv files differently (or append data (appending may not work)).
I will not go through this particular process as I’ll do some more useful posts on this tool later.
A couple of comments after the initial “black box” approach of just opening it up and trying to use it:
- The error messages are not too useful on first viewing. It’s not clear what is wrong, and the error messages are a bit esoteric so on first look do not help.
- A real basic error is not encapsulating names/strings in “” (quotes). The error message for this is not simple either, I suppose it may think it’s a variable that hasn’t been defined (no “” for variables)
- Things are not that obvious. I think you have to have some basic knowledge of the programme and an understanding on what it is doing to become productive. In regards to this I found that this series of tutorials, although longer, an understanding on what is happening:
Publishing & Running your Programme
Lots of Run programme for testing. After getting something that is stand-alone (opens programme, runs, closes programme) I then need to PUBLISH and run it. I’m still trying to get my head around this bit.
On the download you get a programme called UI Robot.exe which will allow you to run the published programme (it has a version history on the programme you publish)
Also there is a thing called orchestrator (I haven’t tried it yet) that will run your Published programme at specified intervals, see this video, a bit long but shows the principles:
<iframe width=”560″ height=”315″ src=”https://www.youtube.com/embed/o6P7wz80LwI” frameborder=”0″ allow=”accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture” allowfullscreen></iframe>
It seems, if you have all the files it needs to automate from on your PC then you need your PC up and running. This is another method, using Windows Task Manager, I quite like this approach as it activates the Uipath Robot on your computer.
<iframe width=”560″ height=”315″ src=”https://www.youtube.com/embed/aZqMEp_s5C8″ frameborder=”0″ allow=”accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture” allowfullscreen></iframe>
End thoughts
This is a bit of a haphazard post. C’est la vie.
I’ve run the UI Robot.exe that sits in the icon tray, offline and it works great for firing up a programme. I do note that if you close the computer and restart, all the previous robot files are forgotten and you have to go and reload them. The amount of effort to fire up Robot.exe you may as well have opened UiPath Studio and used the run command. I’m sure there is some sense to it all but so far I can’t grasp the efficiencies.
I suppose you could give it to someone else to run on their PC, but they’d need to have loaded up the programme and become familiar with it. So handing it out to 3rd parties does not seem to be the main raison d’être of the programme.
Also, running files on your own PC seems not to be its main thrust as, with the orchestrator, there is a presumption that the PC is on at a particular time.
I think maybe I’ll need to set this up on my VPS, as that is running continuously to see if it will interact with orchestrator nicely.
There is definitely a lot of power in this tool, today I’ve been playing with web/data scraping and I can do things that I couldn’t with other tools. That is another post.
I really like the automation processes of this tool, better than macro’s in places, although I think I’ll have to learn AutoIt as it creates .exe files that you can share.
Because this tool works with Data tables, excel and databases I think there is some real potential for this tool. It is definitely not a simple tool and requires a level of understanding of its processes to be able to be effective with it.
It is not obvious in its setup and execution. It is also a bit finicky. Takes a while to debug. When you find the right tutorial, it becomes clear, if you don’t you spend a long time floundering around.
Because of its power its worth learning.