How to disable select all check box from list view

mnreddy
Mega Guru

Hello Community,

 

I have a requirement to disable select all check box from a list view. In the below example, when I select the highlighted check box in red, it auto selects all the fields in that list. I would like to remove that check box and allow users to select each attribute individually. Any guidance is much appreciated. Thank you.

mnreddy_0-1721079479694.png

 

3 REPLIES 3

AshishKM
Kilo Patron
Kilo Patron

Hi @mnreddy,

I dont think there is an easy ( or direct ) solution/option available. It's OOTB feature applicable in list view for all tables data. However you can control the action part using the ACLs.

 

-Thanks,

AshishKM 

 


Please mark this response as correct and helpful if it helps you can mark more that one reply as accepted solution

Satishkumar B
Giga Sage
Giga Sage

Hi @mnreddy 

refer this: https://www.servicenow.com/community/itsm-forum/i-want-disable-the-check-box-and-icon-in-list-view/t...

Alternative:

To disable the "Select All" checkbox in a list view:

1. Create a UI Script:
- Ensure Global is checked.

 

 

addLoadEvent(function() {
var selectAllCheckbox = document.querySelector('input[type="checkbox"][id^="allcheck"]');
if (selectAllCheckbox) {
selectAllCheckbox.style.display = 'none';
}
});

function addLoadEvent(func) {
var oldonload = window.onload;
if (typeof window.onload != 'function') {
window.onload = func;
} else {
window.onload = function() {
if (oldonload) {
oldonload();
}
func();
};
}
}

 

 

……………………………………………………………………………………………………

Please Mark it helpful 👍and Accept Solution✔️!! If this helps you to understand. 

Hello Satish,

 

Thanks for the workaround. My requirement is to disable select all from one particular list view. Any suggestions on how to disable only for one list?

 

Thank you.