This is a migrated thread and some comments may be shown as answers.

Finding True Element Everytime.

2 Answers 38 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
İsmail Yusuf
Top achievements
Rank 1
İsmail Yusuf asked on 17 Jun 2015, 01:14 PM

Hi all,

I have a problem about searching in table. Actually, i need to verify listed items in table contains given input. However, i can not find true element for verification. I added images for you to understand the problem.

2 Answers, 1 is accepted

Sort by
0
Pravallika
Top achievements
Rank 1
answered on 17 Jun 2015, 04:25 PM

Hi,

I suppose your question is to find out all the elements with tag li in the given table right?

 You can achieve it using a coded step with the line of code below:

IList<HtmlListItem> list = Pages.PageName.TableName.Find.AllByExpression<HtmlListItem>("tagname=li", "InnerText=~"+"<yourinput>");

 

Hope this is helpful!

 

Thanks,

Pravallika.

0
Boyan Boev
Telerik team
answered on 22 Jun 2015, 11:29 AM
Hello,

@Pravallika thank you for your input and help.

@Ismail, is this what you want to achieve? 

After you collect all ListItems in a collection you can foreach them and find exactly what you need in them.

If this is not your case please elaborate a bit more on your scenario so we can help you best.

Hope to hear from you soon.

Regards,
Boyan Boev
Telerik
 
The New Release of Telerik Test Studio Is Here! Download, install,
and send us your feedback!
Tags
General Discussions
Asked by
İsmail Yusuf
Top achievements
Rank 1
Answers by
Pravallika
Top achievements
Rank 1
Boyan Boev
Telerik team
Share this question
or