Hello!
New to coding and having an issue. I have the same exact line of code 3 times. Each line of code has a vector image appear when a check box is checked. It works for the first 2 checkboxes but not the last one. I've triple checked and the code is identical and the identifiers are 100% correct (i.e. '#checkbox4', '#vectorImage8')
export function checkbox1_change(event, $w) {
if ($w('#checkbox1').checked){
$w('#vectorImage5').show();
}
else $w('#vectorImage5').hide();
}
export function checkbox2_change(event, $w) {
if ($w('#checkbox2').checked){
$w('#vectorImage6').show();
}
else $w('#vectorImage6').hide();
}
export function checkbox4_change(event, $w) {
if ($w('#checkbox4').checked){
$w('#vectorImage8').show();
}
else $w('#vectorImage8').hide();
}
Thanks!!
I would also encourage you to use more mnemonic names (in lieu of the current generic names).
Check the property panel of the different checkboxes and make sure the Change functions are on there.