I'm using Excel VBA, Selenium and Chrome.
Threse is a dropdownbox box and I'm trying to select an option. Html code is:
<div class="x-form-field-wrap x-form-field-trigger-wrap x-abs-layout-item x-trigger-wrap-focus" id="ext-gen437" style="width: 100px; left: 330px; top: 70px;">
<input maxlength="1" spellcheck="false" id="ext-comp-1233" name="CITTADINANZA" class="x-form-text x-form-field x-field-uppercase x-trigger-noedit x-form-focus" readonly="" style="width: 75px;" />
<img src="data:image/gif;base64,R0lGODlhAQABAID/AMDAwAAAACH5BAEAAAAALAAAAAABAAEAAAICRAEAOw==" alt="" class="x-form-trigger x-form-arrow-trigger" id="ext-gen438" />
</div>
The dispalyed text options are "Si" and "No" but in Html code there are no options, index, value...(it's just an input element; the img element is the arrow you have to click for a dropdown)
I tried to fill the input element using:
driver.FindElementByCss("#ext-comp-1233").AsSelect.SelectByIndex
driver.FindElementByCss("#ext-comp-1233").AsSelect.SelectByValue
driver.FindElementByCss("#ext-comp-1233").AsSelect.SelectByText
driver.FindElementByCss("#ext-comp-1233").Sendkeys
but I recive the error: "Unexpected TagName Error. Expected=select Got=input"
...while Sendkeys doesn't work.
Do you have any idea?
Thanks :)