Hello,
I have two list named list1= [“Apple”,“Orange”,“Mango”] and list2=[“Apple”,“Orange”,“Mango”] and I need to ensure the items available in list1 should be there in list, to ensure if the list contains any unmatched item I have used list1.Except(list2) method to validate. if the values are same in the two list then block should be executed ,if not else part should be executed and used for each loop to iterate the item in list. In my case the for each loop is not executed. Could someone guide me on this
Attached the main.xml file for reference: Main.xaml (12.5 KB)
When you have the two lists identical and perform the except function, it wont return any elements in the output array. Hence the for each loop is not executing.
You can check if List1.Except(List2).count>0 first then perform a for each if the count is greater than 0. If it’s equal to zero, then you can confirm that both the lists are identical.