cancel
Showing results for 
Search instead for 
Did you mean: 

​How to simulate keystroke in cloud studio?

AshwinKatkar
Participant
0 Kudos

I am trying to simulate enter keystroke on an sapgui screen.it was easy with desktop studio like e.sapscripting.key._Enter_, but doesn't work with cloud studio

View Entire Topic

Hey Ashwin,

In order to add a keystroke using the cloud studio, you have 2 options. Using the activity , or doing the keystrokes in a custom script.

Using the activity:

The keys that can be executed are those that you can find in the irpa_core.enums.key. and then using the auto completion function for it. This kind of value will then be added in the "Expression" of the keystroke. Below you can find my own keystroke to execute a Ctrl keystroke.


Using the custom script:
Executing a keystroke is also possible using a custom script.
For this, you first have to add the "Custom script" control into your workflow.


In order to add a keystroke using a custom script, you have to use the irpa_core library function irpa_core.core.keyStroke().

In the brackets of that function, you specify which keys you want to do. These are the same options as for the activity option (Found in irpa_core.enums.key)

Hope this helps!

Kind regards,
Jonis de Klerk

0 Kudos

Hi Jonis,

Thankyou for posting this resolution. I was facing the same issue and your hack worked well!

Regards

former_member748191
Discoverer
0 Kudos

Thankyou Jonis for your answer. Worked like a charm