cancel
Showing results for 
Search instead for 
Did you mean: 

Java Application - There was an error during the spying operation

stefan.hansen
Level 4
Hey everyone.

I am trying to open and Spy a Java application but when I try to Identify anything on the application I get this error:

There was an error during the spying operation.
System.InvalidOperationException: External AppMan reader thread exited before response from query
at BluePrism.AMI.clsAMI.Spy(clsElementTypeInfo& elementType, List`1& identifiers)
at AutomateUI.frmIntegrationAssistant.HandleSpyOrLaunchClick(Object sender, EventArgs e)

This is my first time trying to build a process for a Java based application. in the Application Wizard I located the .jar file, but when trying to Launch it nothing happens. Then I tried with the "Utility - Environment - Start Process" and using the .exe file and then Attach to it that all works, but when spying I get the above error after a few seconds.

If I set the application as a Windows Application in the Wizard and use the exe file, I can launch it but unable to spy any elements but the application window.

This is my setup:
Windows 10 64-bit - v. 20H2
Blue Prism version: 7.0.1.49890
Java: JRE 1.8.0_201 64-bit
Java Access Bridge installed with JRE and enabled in Ease of Access settings.

Any ideas?

------------------------------
Stefan Hansen
RPA Dev
Bestseller
Europe/Copenhagen
------------------------------
4 REPLIES 4

John__Carter
Staff
Staff
Hi Stephan

If the app is Java, then choosing Windows Application in the wizard will not work because the Java spy mode will not be enabled, and the other modes like Win32 and UIA will not work on a Java app.

It would be worth looking at how the application is launched from Windows - see if the shortcut properties contain any special parameters or switches like "C:\Program Files\My App\myapp.jar" /special-switch. It could be that you need to include these in the BP app manager to mimic way Windows launches the app.

It can also be useful to sanity check that JAB is working independently of BP, by using the test tools freely available from Oracle.
http://portal.blueprism.com/customer-support/support-center#/path/1391144872
https://bpdocs.blueprism.com/bp-6-10/en-us/Guides/java-access-bridge/installation-verification.htm?tocpath=Guides%7CJava%20Access%20Bridge%20(JAB)%7C_____4



------------------------------
John Carter
Professional Services
Blue Prism
------------------------------

Hello Stefan,

Just checking - What is the application manager mode you have chosen in application modeler. Try setting it to embedded if not done already and your target application has not dependency on bitness.

------------------------------
Neeraj Kumar
Technical Architect
------------------------------

If I do that, then I get this error when trying to attach to the application:

Internal : Failed to perform step 1 in Navigate Stage 'Attach' on page 'Launch' - Could not initialise Java Access Bridge support - Failed to load Java Access Bridge DLL. The file could not be found in any of the following expected locations -
Application Directory: C:\Program Files\Blue Prism Limited\Blue Prism Automate\WindowsAccessBridge-32.dll
System Directory: C:\WINDOWS\SysWOW64\WindowsAccessBridge-32.dll
Windows Directory: C:\WINDOWS\WindowsAccessBridge-32.dll
Current Directory: C:\Program Files\Blue Prism Limited\Blue Prism Automate\WindowsAccessBridge-32.dll

It seems to be looking for a Java 32-bit dll file when I have 64-bit version installed.

------------------------------
Stefan Hansen
RPA Dev
Bestseller
Europe/Copenhagen
------------------------------

The Shortcut opens the exe file not a jar file. and no special arguments:
29800.png

JavaMonkey and Java Ferret is just empty. I turned on all tracking in Ferret and opened the Java Application. Nothing.
29801.png

------------------------------
Stefan Hansen
RPA Dev
Bestseller
Europe/Copenhagen
------------------------------