18 January 2026:
Sahi Pro is an enterprise grade test automation platform which can automate web, mobile, API, windows and java based applications and SAP.
This forum is now archived and is in read-only mode. Please continue discussions on our improved new Sahi Pro Community forum.
Sahi Pro is an enterprise grade test automation platform which can automate web, mobile, API, windows and java based applications and SAP.
Readonly property for textarea
Hello there,
i just want to check, whether the textarea is in readonly mode or not. I have tried with your scripts but it is not working.
here is your script
1. _assertTrue(_textarea("name").readonly);
2. _assert(_textarea("name").className.indexOf("disabled") != -1);
In the second script it throws the value but its not correct.
i just want to check, whether the textarea is in readonly mode or not. I have tried with your scripts but it is not working.
here is your script
1. _assertTrue(_textarea("name").readonly);
2. _assert(_textarea("name").className.indexOf("disabled") != -1);
In the second script it throws the value but its not correct.
Comments
I tried the first one but could not able to validate the read only text box-
_assertTrue(_textarea("Enter_the_Reason").readonly);
Other assertions for this text field are -
_assertExists(_textarea("Enter_the_Reason"));
_assert(_isVisible(_textarea("Enter_the_Reason")));
_assertEqual("", _getValue(_textarea("Enter_the_Reason")));
Regards,
Gyanadeep
Which version of Sahi are you using?
Please try it out with the latest released Sahi OS version i.e. 4.4.
If the problem continues to persist, please let me know.
_set($disableEnable, ""+ _textbox("telephone").disabled);
value set in $disableEnable will be a string.