protected Step createSelection(JComboBox combo, int index) { Step step = null; if (combo != null && index != -1) { ComponentReference cr = getResolver().addComponent(combo); String value = tester.getValueAsString(combo, list, combo.getItemAt(index), index); if (value == null) { step = new Action( getResolver(), null, "actionSelectIndex", new String[] {cr.getID(), String.valueOf(index)}, javax.swing.JComboBox.class); } else { step = new Action( getResolver(), null, "actionSelectItem", new String[] {cr.getID(), value}, javax.swing.JComboBox.class); } } return step; }