JavaScript - Using variable to set radio button active - Need some help . .
Hello:
I have a script such as this:
var dialogComm01 = {
initialize: function(dialog) {
dialog.load({"comm":this.strComm});
dialog.load({"rd1": true});
this.ServArea = true;
dialog.enable({
"rd1" : this.ServArea,
"rd2" : this.ServArea,
"rd3" : this.ServArea,
The first radio button "rd1" is the default. I would like to set the default via a variable or global variable instead which might be rd2 or rd3 etc. such as like this:
var dialogComm01 = {
initialize: function(dialog) {
dialog.load({"comm":this.strComm});
dialog.load({global.defSA: true});
this.ServArea = true;
dialog.enable({
"rd1" : this.ServArea,
"rd2" : this.ServArea,
"rd3" : this.ServArea,
But it does not fly. Any direction would be greatly appreciated.
Thanks;
Nick
