Highlighted
Super Contributor.
Super Contributor.
323 views

Recorded script is not working for desktop automation

I recorded some clicks in UI of a Java based desktop application. I try to play this script, but it gives error, that element is not present and unable to perform clicks. There aren't any changes in application and no input fields are required. Application is started and elements are visible.

Test steps look like these:

UIAWindow("MyWindow").Move 803,256

UIAWindow("MyWindow").UIAButton("About").Click

 

0 Likes
8 Replies
Highlighted
Honored Contributor.
Honored Contributor.

Re: Recorded script is not working for desktop automation

Hi,

Are you sure you have the correct AddIns installed? Have you launched UFT before luanching the application under test?Has this record & replay worked before?

Does the object spy identify these elements in your AUT?

 

0 Likes
Highlighted
Super Contributor.
Super Contributor.

Re: Recorded script is not working for desktop automation

Yes, addins are installed, this is a Java based application. Application is started by UFT. Yes, I use Object Spy to identify and validate stored elements. No, it hasn't worked earlier, I just recorded it.

0 Likes
Highlighted
Outstanding Contributor.
Outstanding Contributor.

Re: Recorded script is not working for desktop automation


@kovacsakos wrote:

Yes, addins are installed, this is a Java based application.


Unload UI Automation add-in, load just the Java Add-in & try recording again.

_____________________
Rajkumar Rajangam
0 Likes
Highlighted
Super Contributor.
Super Contributor.

Re: Recorded script is not working for desktop automation

I use UI Automation option to record interactions.

0 Likes
Highlighted
Outstanding Contributor.
Outstanding Contributor.

Re: Recorded script is not working for desktop automation

Referring the UFT's guidelines, you should go with Java first & move to UIAutomation only when Java add-in support is insufficient.

Is there any specific reason for not using Java add-in?
_____________________
Rajkumar Rajangam
0 Likes
Highlighted
Super Contributor.
Super Contributor.

Re: Recorded script is not working for desktop automation

There isn't Java in the list, when I use dropdown in recording popup window.

0 Likes
Highlighted
Outstanding Contributor.
Outstanding Contributor.

Re: Recorded script is not working for desktop automation

You have to select the Java Add-in from the Add-in Manager window when opening UFT. If it doesn't show up in the add-inn manager, then you should install the Java add-in from the installer.

_____________________
Rajkumar Rajangam
0 Likes
Highlighted
Super Contributor.
Super Contributor.

Re: Recorded script is not working for desktop automation

I used this:

To display the Add-in Manager if it does not open when you start UFT, select Tools > Options > General tab > Startup Options node and select Display Add-in Manager on startup.

and unchecked UI Automation, but Java was already installed and also enabled in this list.

0 Likes
The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.