CheckedListBox item

Technology specific object identification, supported applications, web technologies, and 3rd party controls.
srdjan.bogojevic
Posts: 4
Joined: Mon Apr 02, 2012 10:43 am

CheckedListBox item

Post by srdjan.bogojevic » Wed Apr 25, 2012 4:51 pm

Hi All,

I've used a CheckedListBox control in application. I read all items in the collection through: IList<CheckBox> items = ....FindChildren<CheckBox>. But, this only works when the number of items set is not large, or more preciselym, when the scroll bar does not appear in the listbox. If you have a large number of items set in a listbox (scroll bar appears) FindChildren returns 0 items, although they exist.

Do I use a good way, or can I get help..

Thanks in advance
Srdjan

srdjan.bogojevic
Posts: 4
Joined: Mon Apr 02, 2012 10:43 am

Re: CheckedListBox item

Post by srdjan.bogojevic » Thu Apr 26, 2012 8:23 am

In the meantime I solved the problem. The answer is: use FindDescendants<CheckBox> () instead of
FindChildren<CheckBox>()

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

Re: CheckedListBox item

Post by Support Team » Thu Apr 26, 2012 8:50 am

srdjan.bogojevic wrote:In the meantime I solved the problem. The answer is: use FindDescendants<CheckBox> () instead of FindChildren<CheckBox>()
... or use the Find<CheckBox>() method using a RanoreXPath created using RanorexSpy.
Great you did it on your own! :D

Regards,
Alex
Ranorex Team