No element found for path after upgrade to 10.5.4

Best practices, code snippets for common functionality, examples, and guidelines.
rshah
Posts: 2
Joined: Mon Apr 10, 2023 1:37 pm

No element found for path after upgrade to 10.5.4

Post by rshah » Mon Apr 10, 2023 2:54 pm

Hello,

Can someone help here as this is blocker for me.

I have C# code which is using below command to find the form using RXPath but when I execute then getting "No Element Found" exception but same code is working with 6.1.1.0 but it is failing after upgrade to 10.5.4, but if I use the spy then able to find the control using same rxPath, so not sure I am missing something because there must be some backward compatibility provided by Ranorex, not sure how spy is able to find the control and my code is throwing exception after upgrade.

Host.Local.FindSingle<Ranorex.Form>("/form[@controlname='MyForm']", 100000)

I removed time duration.
I tried to increase the time duration.
Nothing is working.

Can someone help here?

IvanF
Posts: 151
Joined: Thu Aug 11, 2022 8:55 pm

Re: No element found for path after upgrade to 10.5.4

Post by IvanF » Mon Apr 10, 2023 3:25 pm

hi, may be helpful to share the snapshot here, but have you tried running the recording step on the same element? I wonder if the issue is with the xpath or with the code itself.

https://www.ranorex.com/Documentation/R ... x_Host.htm

I can see Find<T>() or FindSingle() methods, so maybe FindSingle<T>() doesn't behave as it used to.