This project is read-only.

White 2.0 Selecting an Item Within the WPFComboboxes

Jun 7, 2010 at 11:41 AM


After changing to White 2.0, I had a problem selecting an item within the WPFComboboxes. The same code, which was working all the time with the version 1.9 does not work anymore. This problem occurs only with the OS Windows XP.

I have used the following code:

   public static void SetComboBoxValue(WPFComboBox comboBox, string value)


     ListItems items = comboBox.Items; \\-> It is possible to get the items


     ListItem item = items.Where( p => p.Text == value ).First(); 


     // wait to open the list with items


     AutomationElementHelper.SelectAutomationElement( item.AutomationElement );





Jun 8, 2010 at 10:31 PM

I am having the same problem. The mouse goes to the far top corner of the screen and clicks there...

Jun 11, 2010 at 3:23 PM

what is the issue with using combobox.Select method?

Jun 11, 2010 at 11:08 PM

The Select() methode did not work properly. I have tried it many times before, and the problem is that it does not select the item you want to select. Actually it does not make any action on the combobox.

Jun 12, 2010 at 6:04 AM

would it possible to provide a failing test for this.

Jun 15, 2010 at 9:28 AM

Actually I tried the Select() method with the version 1.8, but could not tried it with 1.9 or with 2.0. Unfortunately I have changed all the code, in which I used the Select() method, with the code I have given above. I think it’s worth trying it again as soon as I will have time to change the code again. I will let you know.