Select

Asked

Viewed 233 times

0

Expensive,

I am trying to select an option in a select with the following code and am unable to find a solution.

I can locate the element, but not tell it to select X option.

I’m tracing with the following code:

driver.findElementByXPath("//*[@data-ng-model='passoUmCtrl.model.protocoloAtivo.relacionamento']")

How can I select an option?

1 answer

1


Expensive,

Solved with the following code:

driver.findElementByXPath("//*[@data-ng-model='passoUmCtrl.model.protocoloAtivo.relacionamento']").AsSelect.selectByValue (1)

Browser other questions tagged

You are not signed in. Login or sign up in order to post.