How to close SAP session using UiPath?

I’m working on SAP automation and I have open one SAP window with Admin credential and I have to open another SAP GUI window using Test_User account at multiple time, so how to close SAP window for Test_User and Admin SAP window should be open.
can anyone please help me to solve this issue?

@Ankit_Chauhan

generally if same windows are open the idx would differ so try to use that and close

cheers

how to close it with Kill Process activity, can you please help me?

How to use this SAP Session Window type variable in Kill Process Activity?

@Ankit_Chauhan

Kill process cannot take output of sap window…

If you want to use kill process then after opening first window use get processes and get the opened sap process details and pass that in kill process

Cheers

Try

send the “ALT+F4” key to close the Test_User SAP window.

this error is coming, can you please help me to solve the same error?

@Ankit_Chauhan

Its a collection so use (0) at the end

Cheers

Try GetProcessAdmin(0)

Using Get Process activity I’m getting 272 process, how can I know which one is SAP?

Can you try with process Name instead of process. Identify the SAP process name from Task Manager and use the same in Process Name after removing Process

Thanks for your answer but I got the solution with different method, I just enter the TCode in a particular SAP, which SAP window I want to close, just make a selector for that SAP window, and working fine now.

It’s very difficult to find the particular process name with Get Process activity because multiple process is running in background.

1 Like

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.