We have a little bit of usercode that gets all the items in a list and needs to process them, one by one, by getting the data from the item and processing it.
The code we are using is below and everything works up to the Click.
The next line gets the Children[5] value which is "{Text 'textBlockItemName'} this is the automation ID of the element we are after.
The question is how do I now get the text, or any other, property of that Text control ?
I can't find a way of getting properties for that item, thanks for any help.
Code: Select all
var favouritesList = repo.WPF.Place_Order_Form.Select_Order_Items.Favourites_Tab.FavouritesList;
int itemCount = 0;
IList<Ranorex.ListItem> listitems = favouritesList.Items;
foreach (ListItem listitem in listitems) {
//If not the header row then remove the favourite
if (itemCount > 0)
{
listitem.Children[1].Click();
tst_ocs_examination = listitem.Children[5].ToString();