I'm building and automated test script for a webapp using selenium and I'm trying to use the waifForCondition function of the API where it will wait until a JS script evaluates to true.
I currently have this source on the page:
<input id="modifyHostsForm:idDnsIp0_0" type="text" name="modifyHostsForm:idDnsIp0_0" readonly="" disabled="">
Which should change to:
<input id="modifyHostsForm:idDnsIp0_0" type="text" name="modifyHostsForm:idDnsIp0_0">
As soon as I put a certain value on another field and fire the "blur" event on it (and this field thus becomes "enabled").
And I'm trying to execute the following JS script to test when this field is enabled (basically what I found from "Googling"):
document.getElementbyId('modifyHostsForm:idDnsIp0_0').disabled == false
However I'm getting a SeleniumException which indicates that "Object doesn't support this property or method". What can I do here? Any help would be appreciated.
readonlyattribute would also workdisabled == false??