Discussion about developing the ProcessMaker application and suggestions for improving it
#828820
Hi guys,

I am looking for a code to hide or unhide a radio button based on a dropdown values.
For example:
There are 2 radio button, radio1 and radio2.
There is a dropdown that is named type and has 2 values, "ok" or "not ok"
If "ok" from dropdown selected then radio1 appears and radio2 disappear and if "not ok" selected then radio2 appear and radio1 disappear.
What is the code in JavaScript?
Thanks for your consideration.
#828827
Hi,

Please test below is what you want:
Code: Select all
//== test select myDropdown to "ok" than disable/hide/show myRadio
$("#myDropdown").setOnchange(function(newVal, oldVal){     //put your id/var  to replace myDropdown
	if (newVal === "ok") {
      //$("#myRadio").getControl().attr("disabled", true);      //put your id/var to replace myRadio
      $("#myRadio").show();
    }else{
      //$("#myRadio").getControl().attr("disabled", false);
      $("#myRadio").hide();
    }
})

Get an instant solution to move emails to MBOX for[…]

Most Demanding OST to PST Converter

The most demanding OST to PST Converter is TrijaT[…]

Betvisa clone scripts are pre-built software solut[…]

A Bet365 Clone Script is essentially a ready-made […]