jscript to enable or disable text box based on drop down list
Hi,
I'm trying to do a simple jscript to determine whether some specific text box is enabled or not in v9. My jscript is as below. function addOnLoad is called during form load and all dependencies of the involved form control is ok when i test it on server side.
Can someone share any idea why it's not working??
function addOnLoad()
{
$find("myDropDownList")._element.onchange =
function () { testDisable(); };
}
function testDisable()
{
if(($find("myRadioButton").get_value())=="radioValue 1" && ($find("myDropDownList").get_selectedItem())=="dropDownValue1")
{
$find("textboxA").editor.enable();
$find("textboxB").editor.disable();
}
if(($find("myRadioButton").get_value())=="radioValue 1" && ($find("myDropDownList").get_selectedItem())=="dropDownValue2")
{
$find("textboxB").editor.enable();
$find("textboxA").editor.disable();
}
else
{
$find("textboxA").editor.disable();
$find("textboxB").editor.disable();
}
Categories
- All Categories
- 123 Developer Announcements
- 54 Articles
- 155 General Questions
- 149 Thrust Services
- 57 Developer Hackathon
- 37 Thrust Studio
- 20.6K Analytics
- 4.2K AppWorks
- 9K Extended ECM
- 918 Core Messaging
- 84 Digital Asset Management
- 9.4K Documentum
- 33 eDOCS
- 190 Exstream
- 39.8K TeamSite
- 1.7K Web Experience Management
- 10 XM Fax
- Follow Categories