UiPath detecting Java closed window

I’m running a task that start an application, search a register by an ID and open a window to insert some data and closes that window, and then repeat that for “n” transaction items, but UiPath is detecting that window that was closed as if it were open, and it’s crashing the task, I have to restart the application every time that I execute an transaction item. It’s like a “ghost window”.
If I try to store the attached window to a variable and then close it, instead of close the window, it closes the application, it’s not a good thing to start the application for each transaction item.
Anyone has a solution for that?

What do you mean “detecting” like it was open? I dont work a lot with java applications but, you should close child windows like humans would (using X, pressing ESC or whatever) and not using Close Window activity.

I tried to close using all the options available, and it closes. Step by step below:

1 - Open application
2 - Search a data by id from transaction item
3 - Open window and input all data from transaction item
4 - Close the window
5 - Search a data by id from the next transaction item
6 - Open window to input all data from transaction item
Here, UiPath is mapping the window already closed before and not the opened one, that have same selectors, no errors occurs but the data is not being inserted on the opened window, only works if I restart the application and star the steps before again.

Instead of selectors, can you try image exists ? and close the window as soon as work with it is complete and reopen for new transaction ?

Hi @joaopedrosmelo,

Welcome to the community !

So , to stop uipath detecting the ghost window , make use on on element appear activity .

This activity has 2 properties
Wait Active
Wait visible

Please try with both the option one by one and then clicking both.

In your Automation, You can make changes like:

  1. fetch only when the element appear /visible on screen.
    2.Fetch only when the element does not appear on screen.For this you have to look for a different element which is supposed to vanish after transaction.


Thank you all for the help! I solved that using Get Active Window instead of Attach Window.

1 Like

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