Finding a Web Link
Posted: Mon Apr 02, 2012 7:05 pm
Hi,
I am trying to find a link in AUT and click it.
The following code is working for me.
But, the following doesn't. Can you give me an insight, why?
Thanks,
Suraj
I am trying to find a link in AUT and click it.
The following code is working for me.
Code: Select all
Ranorex.WebDocument mppApp = repoMPP.HomePage.Self;
Ranorex.Unknown mppElement = mppApp.FindSingle<Ranorex.Unknown>(".//a[@id='CompanyManagementCheckButton']");
mppElement.Click();
Code: Select all
Ranorex.WebDocument mppApp = repoMPP.HomePage.Self;
Ranorex.Link mppElement = mppApp.FindSingle<Ranorex.Link>(".//a[@id='CompanyManagementCheckButton']");
mppElement.Click();
I prefer to know the type of object I am finding.I get the error "The element does not support the required capability 'link'. "
Thanks,
Suraj