cancel
Showing results for 
Search instead for 
Did you mean: 

Best pratice for SAP Automation

NidhiMehata
Level 3
For Sap Automation in Blueprism what is the best pratice for logging in into SAP logon app.

There are 2 approaches:
1. Used in sap accelerator, where in actions are present to click on env required, enter credentials, click on enter button etc.
2. Use code stage to instantize an sap application as below
Dim session As Object
Dim Application As Object
Dim Connection As Object

Application = CreateObject( "Sapgui.ScriptingCtrl.1")
Connection = Application.OpenConnection( "conn-name", True)
Session = Connection.Children(0)

session.findById("wnd[0]/usr/txtRSYST-MANDT").text = "client"
session.findById("wnd[0]/usr/txtRSYST-BNAME").text = "username"
session.findById("wnd[0]/usr/pwdRSYST-BCODE").text = "password"
session.findById("wnd[0]/tbar[0]/btn[0]").press


Which is the prefered way to launch and get to the homepage of SAP?
2 REPLIES 2

Hi, Nidhi,

I think that it depends 🙂 and I am not going to give you clear yes/no answer, unfortunately.

First assumption for the second approach is that SAP Scripting is enabled which might not be always the case so it wouldn't work in such an environment.
Apart of that I would say that it also depends on the user skillset. The first approach if for whatever reason it does not work every Blue Prism developer can fix it through respying or reconnecting, etc. The second approach if it does not work only Blue Prism Developer with VBScript knowledge and some previous programming experience can analyze and fix. And there is a large group of people without this skillset.

I believe that there are many other parameters to take into account and I touched only the obvious ones.

Regards,

Zdenek

EmersonF
MVP

Well, it depends!
But I will tell you how I currently do it and was approved by the company's COE RPA.
The login service is done by mapping, then we use our Blue Prism password vault to obtain the password and password, and in sequence we navigate to perform the login, once within the SAP environment, any and all interaction is done via SAP SCRIPT, for safety and speed.
The solution will depend on your company and how flexible it is to use the tool, for example some companies are not allowed to use SCRIPT in SAP production environments.

If I helped you, mark it as useful =]

Sr Cons at Avanade Brazil