Forum Discussion
I suggest you read through Understanding Web Object Identification and Object Models.
Note, that FindElementByAccessibilityID method returns the first found object that matches the condition in the tree structure of Process("uk.co.rpssoftware.designer.anglian")
You need to get the correct Parent for FindElementByAccessibilityID to work.
Also, I think your coding is incorrect, as your Find method looks like this (if you remove all the other stuff),
target = parentLevel.Find("FullName", "regexp:FindElementByAccessibilityId\(\"Cornice\\n\"\)*", 20000);
Try something like this,
target = parentLevel.Find("FullName", "Cornice\\n", 100);
- Petewilson3 years agoContributor
I was attepting to do something like was in the RegExp help page (https://support.smartbear.com/testcomplete/docs/reference/misc/regular-expressions.html)
// Get Notepad's main window by using a regular expressio
window = notepad.Find("WndCaption", "regexp:.* Notepad", 5);
so i didn't have to put the entire FullName for every menu option. I've used the Name attribute in the end
target = parentLevel.Find("Name", "StaticText\(\"" + Cornice + "\\n\"\)", 100);
which works but doesn't explain why the regexp, like below didn't work
target = parentLevel.Find("Name", "regexp:.*Cornice*", 100);
Related Content
- 12 years ago
- 2 years ago
Recent Discussions
- 19 hours ago
- 5 days ago