hello,
I have a project where i need to have a checkbox, once clicked, show more fields for the user to input data into. I created a checkbox component and added the following code to an onclick event.
var AltMgr_Label = document.getElementById('AltMgrLabel')
var AltMgr_FirstNameLabel = document.getElementById('AltMgr_FirstNameLabel')
var AltMgr_LastNameLabel = document.getElementById('AltMgr_LastNameLabel')
var AltMgr_FirstNameText = document.getElementById('AltMgr_FirstNameText')
var AltMgr_LastNameText = document.getElementById('AltMgr_LastNameText')
if(!checkbox.checked)
{
AltMgrLabel.visible = "True";
AltMgr_FirstNameLabel.visible = "True";
AltMgr_LastNameLabel.visible = "True";
AltMgr_FirstNameText.visible = "True";
AltMgr_LastNameText.visible = "True";
}
But when i test the project, checking the checkbox does not set the fields/labels to visible. I configured each field as Visible = False in the component editor.