logo

NJP

Error: Checkbox is disabled but it's possible to select

Import · Mar 22, 2021 · article

My Checkbox is disabled but it's possible to select and this action save effectively my record.

We're testing our development when faced this behaviour on the screen the checkbox is disabled, but instead of the common action that should be not clickable, could be clicked and saved.

image

Therefore we start to debug. How to do it?

Image Description
01. F12 Debugger
image 02. Open Console Tab
image 03. Search by error
image 04. identifying the error you'll be able to fix it, in my case was a UI POLICY Error's cleary saying: Uncaught TypeError: g_user.getValue is not a function
image Updated to image 05. Go to script and fix it g_user.getValue updated to g_form.getValue
image 06. Save and the error gone, as result my checkbox can't be clicked

.

image

summary

upgrades

Servicenow versions

View original source

https://www.servicenow.com/community/developer-articles/error-checkbox-is-disabled-but-it-s-possible-to-select/ta-p/2311294