UIElement is no longer valid

I am trying to create a relative simple routine that takes a list support tickets, opens our intranet and using an input box finds the ticket by number and changes the status of the ticket.
The routine opens the intranet site on the tickets list page enters the first ticket and changes the status which goes back to the ticket list, it is at this point I get the error UIElement is no longer valid when it needs to enter the next ticket number.
I have checked the selectors and there is nothing particular that its is looking for but it will not work.
Does anyone know where I might be going wrong.
Thank you

By looking at the selector i could see the indexing “idx” attribute .
The best practice is to always get rid of “idx” but anyway you can use upto limit as 1 or 2 not more than that.
So please use UiExplorer and try to add parent id or class and uncheck idx field which will help you to fine tune the selector.


so there are more then one input box exists on that page? and are you filling all?

then idx will be useful at that point.

what other thing you can do first type into first input box and you can use tab hot key as well.

Let me know if still you are not able to sort it out/


Below will be partially a speculation:

From my experience UiElement is no longer valid shows due to some caching issues - it seems like once an element is located it’s cached somewhere, but if the page changes in the meanwhile, it might make the reference invalid.
At least that’s what I’m experiencing in one of the applications (a table is being redrawn under some circumstances while robot was operating on it). But, I was actually storing the UiElement in a variable, while you don’t seem to - meaning that the caching might be happening for the page structure itself on first search and that snapshot is being searched to increase performance. Since not all pages correctly report readiness status (if they’re dynamic and don’t inform the browser that they’re changing or never go to Complete state) it might throw the robot off…

But aside of “I’m having similar issues” rest is a speculation on why exactly it happens :frowning:

Maybe someone from Uipath could shed more light at it - @badita?


Thanks for all the feed back guys,there are more than one input box but I only need it to use the one, I will be looking at it again later.


Who is to be blamed here , the Code or the Web App?

When I do Ctrl+F5 (force cache clear), it works fine ( Find Element > Click… Variable Selector)

1 Like

I’d wish I’d know :frowning:
@badita ?

1 Like


Can someone please give the correct reasoning and resolution for this error message. In my environment this occurs sporadically on a specific website which I do not have control over.

This occurs at a specific location which is confirmation screen OK button. The OK button is not a dynamic selector.

UiPath.Core.Activities UiPath.Core.InvalidUiElementException: The UiElement is no longer valid ---> System.Runtime.InteropServices.COMException: Invalid UI node. at UiPath.UiNodeClass.FindFirst(UiFindScope scope, String nodeID) at UiPath.Core.UiElement.FindFirst(FindScope scope, Selector selector) --- End of inner exception stack trace --- at UiPath.Core.Activities.ScopeActivity.OnFaulted(NativeActivityFaultContext faultContext, Exception propagatedException, ActivityInstance propagatedFrom) at System.Activities.Runtime.FaultCallbackWrapper.Invoke(NativeActivityFaultContext faultContext, Exception propagatedException, ActivityInstance propagatedFrom) at System.Activities.Runtime.FaultCallbackWrapper.FaultWorkItem.Execute(ActivityExecutor executor, BookmarkManager bookmarkManager)

1 Like

I am also facing the same issue while doing web automation.
“message”: “Invoke workflow file: Click ‘INPUT IsVehicleInsured…’ : The UiElement is no longer valid”,
“timeStamp”: “12:30:43”,
“level”: “Error”,
“fileName”: “Main”
I am doing data entry from excel to web application using parallel process activity
oftenly I face the above error message
Can some one help me to solve the issue

Thanks in Advance
Jothyprasanth M

1 Like

Same problem here.
I guess Andrzej explanation is good : Page auto refresh, but UiPath do not detect that. And then when trying to access to some object, uiPath throw an error saying elment is no longer valid.
Like several peoples here, i’d like to know how to handle this error.

Please some inside tech guy answer this :slight_smile:

1 Like


Currently testing this setting in IE 11. Hopefully it fixes the issue.



Changing this setting worked for me on a very similar problem I was having.

1 Like

Having the same issue, and it bumped on me often.
It really seems like having something to do with cache.
For example, I was having a very simple automation to open a browser (Mozilla Firefox), it works for one whole day and several hours the next day morning, and then suddenly it crashed to this error. When I cleared Mozilla cache, it all worked fine.

Hoping there is better explanation on this :frowning:


I’m having the same problem.
Changing my browser settings isn’t an option.
Is there an explanation for this problem already? I’m using a professional version of UiPath.

This one did it for me. Very nice! =)

Has anyone figured out a solution to this, other than changing the browser settings?

I am facing similar issue in “Type Into” activity in a web automation project. Current selector has been working well all this while and now fails sporadically (may work fine or may not if I try running the automation job in the next attempt)

Message: The UiElement is no longer valid

Source: Invoke - Customer Forms: Invoke- OpenCustomerForm: Type into 'INPUT - Email

Exception Type: InvalidUiElementException

UiPath.Core.InvalidUiElementException: The UiElement is no longer valid —> System.Runtime.InteropServices.COMException: Invalid UI node.
_ at UiPath.UiNodeClass.WriteText(String text, UiInputMethod inputMethod)_
_ at UiPath.Core.UiElement.WriteText(String text, InputMethod method)_
_ — End of inner exception stack trace —_
_ at UiPath.Core.Activities.InvokeWorkflowFile.EndExecute(AsyncCodeActivityContext context, IAsyncResult result)_
_ at System.Activities.AsyncCodeActivity.System.Activities.IAsyncCodeActivity.FinishExecution(AsyncCodeActivityContext context, IAsyncResult result)_
_ at System.Activities.AsyncCodeActivity.CompleteAsyncCodeActivityData.CompleteAsyncCodeActivityWorkItem.Execute(ActivityExecutor executor, BookmarkManager bookmarkManager)_

Selector in use:

Upath version: 16.2.6274.33252.
Any help will be greatly appreciated.

Hi @dw_amitabh,

Use uiexplorer to get exact selector.
We can use 2 methods to make selectors dynamic:

Adding wildcards characters in selectors

  • Asterisk (*) – replaces one or more characters

  • Question mark (?) – replaces a single character

Refer the below link
Selectors with Wildcards

Arivu :slight_smile:

Hi @arivu96 ,

I have not still undertood it!

I open an app and was able to selected the text and change it for a new value stored in a variable.

Therefore, when i tried do it again i have the following message: “Type into ‘billing.exe WIP’ : The UiElement is no longer valid”

Do you have any idea about to solve it?

best regards,


Same problem. As long as selectors are essentials in such automation loosing UiElement in web browser makes UiPath unreliable tool.

Why is this happen?

1 Like