Skip to Content
Technical Articles
Author's profile photo Nabheet Madan

My trials with SAP iRPA – Hello Excel

Posts in the series

Part Description
1 Hello Excel – Set Cell value and different formatting options
2 Hello Excel – Reading range of data via inbuilt activity, look at Concept of Context briefly and scripting
3 UI Designer design screen for data read from excel file


First of all a Happy New year, every one has his/her learning list for 2020 ready(for inspiration check these brilliant one’s from DJ Adams here, Marius here and Witalij here ) so do I?. The SAP IRPA of-course is in my to do list. So through the series of blog post I will share my experience of my trials.  As a first impression I found the SAP IRPA solution to be complex one as compared to the other solutions such as UIPath.

So that is what triggered these posts where we will go from pretty basic stuff to the complex one’s.  This will help me as well the readers in understanding it better. Where shall we start I believe excel must be on everyone’s list so thought of starting from here!

What we are trying to do?

In the very first post we will simply try to write data to an excel file cell and use different formatting options nothing much fancy, slowly the scenario’s will get complex.

Let’s Begin

Following this great blog post from Vijay I have my set up ready and running. I would recommend everyone who wants to learn is to first complete the basic tutorials from here and then can do the openSAP course. Why tutorial first and then the course is because tutorial did not take much time and gave me a high-level overview and head start. I will say both are great resources, its more of an individual preference. The first time we opened the studio and the information was overwhelming so many blocks but no problem let me try to explain it via a snap shot

So lets create our first project which will update and format the excel cell value. Please do remember we have different options of achieving the same thing such as via screen shots, workflows or scripting etc.

The RPA provide us with in built libraries to interact with such as excel, outlook etc. So as next step we will include the excel library. Go to scripts tab->Right click->Include library script for excel->Save

So now everything is set lets design our first workflow which is nothing but sequence of steps we want to take. Go to workflow tab -> Right click Global-> Create new workflow-> Add a sequence type activity

Now double click the sequence and we will add our our steps from excel library. The first step is to initialize the excel and open the sheet.

Set the cell value. We will hardcode it for time being to RPA, in future posts we will see how to specify them dynamically via context etc.

Set the background color

Set the font size

Make it bold and change the font color

Save and Close the excel. Then add the end the excel step why…? So the excel running task in task manager shall be closed and resources are set to free

Press save and you can see the JS code being auto generated for the same.We are all set let’s build it and run it.

Final Demo

So now we expect a blank excel cell to be filled with value and different formatting applied.

What is next?

We have seen here basic interaction between an excel cell and RPA, in next post we will take it to the next level to bring the concept of context and reading and writing multiple rows of data. Feel free to provide your feedback!

Assigned Tags

      You must be Logged on to comment or reply to a post.
      Author's profile photo Vijay Sharma
      Vijay Sharma

      Nice Nabheet 🙂 .. so now we have atleat one common learning task for 2020 :-)...


      Author's profile photo Mohit Sharma
      Mohit Sharma

      Hi Nabheet, Its very insightful.

      Author's profile photo Bruno Correa
      Bruno Correa

      Sorry, but as almost all content for iRPA so far, this cant be followed by beginners... If you just click play, nothing happens, i guess we need to after, go to agent system tray icon and hit Test 'Project Name' right? and then if you get an error (i did cause didnt put the double back slashes in excel path) also my studio dont say anything, just i see a popup saying a trace file has been created... Also, should the project be stopped after closing excel? I appreciate all content being released as i am coming from uipath and this is being very hard to learn so far, so thx!

      Author's profile photo Nabheet Madan
      Nabheet Madan
      Blog Post Author

      Hello Bruno

      Thanks for the feedback. Once you click run then you need to go the agent icon and click on the project which is highlighted in the video demo.

      Regarding your second error  "(i did cause didnt put the double back slashes in excel path)" If you look at the help which get on the field it mention about double back slashes. I also got confused here but that is part of the learning curve i will say.

      The trace file is like you have got some error in your code which has caused program to terminate same you can see in the log window.

      We are in the development environment so we normally stop it and then make changes, build it and run again.

      I will be honest here i am also trying to get my head around SAP Intelligent RPA along with Automation anywhere and UIPath i can feel the difference.  I will recommend doing the openSAP course. first if you have not done already it will help you in settling down.

      In case you are still stuck you can post your queries as Q&A and our community will be happy to help you.








      Author's profile photo Vinay Kumar Thanugundla
      Vinay Kumar Thanugundla

      Hi Nabheet,


      Followed step-by-step . Achieved the result.

      And one important point…I had the same error of double backslashes reported by the tool. However, it got me to wear the developer hat until resolution .

      (And , i suggest all the users to wear the Hat if you are following different exercises outlined above).

      I am NOT taking any sides here. You are free to follow your own approach.


      I am an SAP Technical manager. We are currently using Blueprism RPA tool(since SAP iRPA was not available then).  However, most of our bots are interacting with SAP.

      Keep enlightening our community. I will try to prepare an exercise, if i run into any new tools in SAP iRPA.


      One question : How do I open the 'Desktop Agent' window appear in my windows  system. 

      I know that its running via the Window services, however, i am unable to locate it in the Windows tray(extreme right corner-bottom area). Could you guide me here.

      Author's profile photo Nabheet Madan
      Nabheet Madan
      Blog Post Author

      Hello Vinay Kumar Thanugundla

      Thanks for the feedback.As soon as we run our app during development the desktop studio starts. You are irght its right corner bottom area. If see the icon just a click and it opens up the running project window.




      Author's profile photo madhavi ess
      madhavi ess

      Hi Nabneet,

      i have done as described, the only problem is my excel is showing null or no object in debugging mode..could anyone help me out,im new to irpa

      Author's profile photo SAP Learner
      SAP Learner

      Great Post Nabheet. Share some more demo scenarios for us to learn.




      Author's profile photo Jirí Ružicka
      Jirí Ružicka

      Dear Nabheet, Hello,

      first of all I would like to thank you for the great guideline and time you spent on it.

      I tried to proceed exactly the same, step by step, but I couldn't open the excel file. How is it possible?

      Below, I also include scripts that match yours (without formatting), and when I run the agent it throws me this message (see below)
      Can't you tell me where the mistake may be or what I'm doing wrong?

      Thanks in advance for your quick response in this matter.

      // Initialize Excel
      ctx.options.excel.newXlsInstance = true;
      ctx.options.excel.visible = true;
      ctx.options.excel.displayAlerts = false;
      // Open Excel'C:\Users\peter.jurik\Documents\RPA\excel\\setExcel.xlsx');
      // Set cell
      ctx.excel.sheet.setCell(1, 1, 'RPA');
      // Save Excel;
      // Close Excel
      // End Excel
      sc.endStep(); // end Scenario

      And the error message while running debugger:

      Author's profile photo Nabheet Madan
      Nabheet Madan
      Blog Post Author

      Thanks for the feedback. From the log i can see path is not correct. It is missing slashes.

      Author's profile photo madhavi ess
      madhavi ess

      HI Nabheet, even im facing the same issue..but i have provided the double slashes which is not being displaced in debugging mode

      'C:\\Users\\madhavi\\Documents\\SAP\\Intelligent RPA\\Desktop Studio\\ReadDataFromExcel\log\\book1.xlsx'



      Author's profile photo Srinivas Rao
      Srinivas Rao

      Hi madhavi ess – I was also getting the same issue and I later realized that I had named the file as "PO.xlsx", so the full name becomes "PO.xlsx.xlsx" :D....

      Please check if this is not the case for you 🙂

      Author's profile photo madhavi ess
      madhavi ess

      hi srinivas i tried this is not working ...i am getting "No excel found create a new one"