document.getElementById("cbox0").checked = true;
I am using this statement to auto check a checkbox but i get TypeError: Cannot set property 'checked' of null for CheckBox this error. I have tried to use if statement to check if its not a null but it also give me the same error.
jsp+='<input id="cbox'+index+'" type="checkbox" name="compare" value="'+rightCard.oid+'" onchange="myFunction('+index+')"><label for="cboxCard'+index+'"> </label>';
Aucun commentaire:
Enregistrer un commentaire