Forum Discussion

sshah1's avatar
sshah1
Contributor
9 years ago

Is it possible to pass variable value as click item index in combo box?

Hi,

I am new to Test complete 11, In my keyword test, I have created variable (interger) and I like to use that variable to select dropdown list item. Is is possible to do that? If yes, which operation I should use?

 

Thanks,

Samixa

2 Replies

  • Marsha_R's avatar
    Marsha_R
    Champion Level 3

    If your index looks something like this when it's hard coded:

     

    object.index(1)

     

    then instead of the 1, use

     

    KeywordTests.Variable.MyIndexVariable

    or

    Project.Variable.MyIndexVariable

     

    I find it easier to write the test initially with a hard-coded value so I can see the mechanism work, and then change it to a variable.