FindSingle timing out

Class library usage, coding and language questions.
anzacthecat
Posts: 31
Joined: Mon Jan 10, 2011 1:05 pm

FindSingle timing out

Post by anzacthecat » Wed Mar 16, 2011 2:54 pm

I have a lot of checkboxes on a page and I'm trying to check specific ones using:

clickItem(WebDocument webDoc, int ctrIndex1, int chkIndex2)
{
String searchTerm = ".//input[@type='checkbox' and id~'.*ct10" + ctrIndex1 + "_chk" + chkIndex2+"']";
InputTag checkbox = webDoc.FindSingle<Ranorex.InputTag>(searchTerm, 1000000);
checkbox.Checked = "true";
}

the searchTerm generated works fine in Spy. What am I doing wrong?

User avatar
Support Team
Site Admin
Site Admin
Posts: 12145
Joined: Fri Jul 07, 2006 4:30 pm
Location: Houston, Texas, USA
Contact:

Re: FindSingle timing out

Post by Support Team » Wed Mar 16, 2011 3:28 pm

Hi,

Have you checked if you RxPath is correct you try to build with your string construction?
Please try your built RxPath with Spy if the element can be found using your RxPath.

Regards,
Peter
Ranorex Team