Windows's tool called "Interactive Service Detection" manages how a program can interact with the desktop, showing application in the front or leaving them in the background.
Before running the instance, the following changes must be made in the target machine:
1. In Services.msc, make sure that "Interactive Services Detection" is started and running.
2. In Windows 8 or above, starting "Interactive Services Detection" service will throw error as (Interactive Services Detection “Error 1: Incorrect Function").
3. To resolve above error, Go to the 'Start' menu and in the search box type “regedit”, then go to CurrentControlSet\Control\Windows , change value of "NoInteractiveServices" from 1 to 0. (based on: https://blogs.technet.microsoft.com/home_is_where_i_lay_my_head/2012/10/09/windows-8-interactive-services-detection-error-1-incorrect-function/ )
4. Now start the "Interactive Services Detection" service and the error will be resolved.
5. Restart PAM.
Now, the target machine will be ready to to start any program in the front, the following example can be used:
Operator "Run Script":
- Script extension: .bat
- Inline Script:
start "" "C:\Windows\System32\notepad.exe"
When the above instance runs in a target machine, the following message will appear in ends user's Desktop:
When the End User click on "View the message", the program will be shown as follow:
Once the End User closes the program, the process instances will finish too.