Desktop Automation

Introduced in Kofax RPA 10, Desktop Automation helps you automate any work process involving computer applications such as:

  • Native Windows applications

  • Native Java applications

  • Legacy terminal applications

  • Other applications presenting a GUI on a Windows system, such as Citrix clients

See Introduction to Desktop Automation for more information.

Note Desktop Automation service relies on Windows UI Automation API. Do not run any UI Automation API clients on the same computer simultaneously with Desktop Automation Agent.

Also, the Getting Started with Desktop Automation Guide is available in the Kofax RPA documentation set that walks you through the process of using the Desktop Automation to build a robot.

Note The Desktop Automation Service cannot automate, remove the focus from, or generate input, such as keyboard input or a mouse click, for an application that has the High integrity level as defined by Windows. The Desktop Automation Service runs as a process with the Medium integrity level and cannot generate input for applications with a higher level. Example of applications running at the High integrity level is the Task Manager, System Properties, or applications ran as administrator.

Also, the Desktop Automation Service cannot generate a tree for applications with a higher integrity level.

Workaround: Run the Desktop Automation Service as administrator to increase the integrity level to High. Or, install the Desktop Automation Service with the virtual input driver and set the environment variable KOFAX_RPA_VIRTUAL_INPUT to Y. For more information on the latter, see "Install the virtual input driver" in the Kofax RPA Installation Guide.

A note for Windows 10 users

Windows Start menu is not selectable and does not appear as a tab in the Recorder View when running Windows 10 as a remote device with Kofax Kapow version 10.3.0.1 and later.

Symptom
A robot is significantly slower when Desktop Automation Service (DAS) is running on Windows 10 (or corresponding server versions) compared to Windows 7. Additionally, it is possible that the robot using DAS running on Windows 10 (or corresponding server versions) is not able to identify some elements (such as a window, a popup or other) that can be identified if the DAS runs on Windows 7.
Details

Kofax Kapow version 10.2.0.3 and to version 10.3.0.0 included a patch to fix an issue observed with Universal Windows Platform (UWP) applications also known as Metro-style applications on Windows 8.1 and Windows 10. While looping (enumerating) the open applications on a Windows desktop (which is done five times per second), the traditional method would skip those applications.

With this patch the robots use a method provided by the Microsoft UI Automation API that includes the Metro-style applications, but also has two adverse effects:

  • In general this method consumes more CPU power and takes longer, and as the Desktop Automation Service (DAS) is single threaded, it leads to performance degradation across all installations.
  • For specific applications, at least in one instance we have seen this method leading to 100% CPU usage for both the DAS (the node.exe process) and the application itself.

Resolution

For versions 10.2.0.3 to 10.3.0.0 there is a method of switching back to the original enumeration algorithm by setting the following environment variable:

KAPOWHUB_APPLIST_VERSION=1

Follow these steps to add this environment variable:

  1. Stop DAS (right click the DAS system tray icon and select the option from the shortcut menu).
  2. Open Task Manager and make sure there are no node.exe processes running (stop them, if there are any).
  3. In Task Manager, stop all DesktopAutomationServiceControl.exe. This is very important because this process is the DAS Controller (includes the sys tray icon). When DAS is started, the Controller is getting its environment variables from the system and the Desktop Automation Service is getting its variables from the Controller. So for a new environment variable to be used in DAS, the Controller has to be restarted too.
  4. Set the Environment variable.
  5. Restart Desktop Automation Service (from Start > Programs, it will restart both the system tray app and node.exe).

If this environment variable is added, the performance of DAS running on Windows 8.1 and 10 improves and Metro-style apps are not automated.

Kofax Kapow version 10.3.0.1 improves a few minor performance issues from the previous version and reverts back to using the original enumeration method as default. Therefore, in Kofax RPA version 10.3.0.1 and later there should be no performance problems between Windows 8.1 or 10 and Windows 7, but the Metro-style apps are not automated by default leading to disappearance of the Windows Start menu tab from the Recorder View.

If you want to automate Metro-style apps, set the following environment variable:

KAPOWHUB_APPLIST_VERSION=2

The steps to set this variable are the same as above. If this variable is set, please be aware this can lead to performance degradation.