If you wanna check whether a checkbox is selected or not in visual force please use the below jQuery snippet.
jQuery code snippet:
Thanks for visiting...!
jQuery code snippet:
function updateSelRecords(checkboxid or checboxstleclas) { var chbxClassId = '.'+checboxstleclas; // if your receiving checkbox styleclas or var chbxClassId = '#'+checkboxid; //if your receiving checboxId if($(chbxClassId).prop('checked')) { alert('Checkbox selected'); } else { alert('Please select at least one record'); return null; } }
Thanks for visiting...!
No comments:
Post a Comment