Overview of the Flex Select Method Using Name or Index

You can record Flex Select methods using the Name or Index of the control that you select. By default, Silk Test Workbench records Select methods using the name of the control. However, you can change your environment to record Select events using the index for the control, or you can switch between the name and index for recording.

You can record Select events using the index for the following controls:

  • FlexList
  • FlexTree
  • FlexDataGrid
  • FlexAdvancedDataGrid
  • FlexOLAPDataGrid
  • FlexComboBox

The default setting is ItemBasedSelection (Select event), which uses the name control. To use the index, you must adapt the AutomationEnvironment to use the IndexBasedSelection (SelectIndex event). To change the behavior for one of these classes, you must modify the FlexCommonControls.xml, AdvancedDataGrid.xml, or OLAPDataGrid.xml file using the following code. Those XML files are located in the <Silk Test_install_directory>\ng\agent\plugins\com.borland.fastxd.techdomain.flex.agent_< version>\config\automationEnvironment folder. Make the following adaptations in the corresponding xml file.

<ClassInfo Extends="FlexList" Name="FlexControlName"  EnableIndexBasedSelection=”true” >



With this adaption the IndexBasedSelection is used for recording FlexList::SelectIndex events. Setting the EnableIndexBasedSelection= to false in the code or removing the Boolean returns recording to using the name (FlexList::Select events).
Note: You must re-start your application, which automatically re-starts the Silk Test Agent, in order for these changes to become active.