Use PDIs? Take our 5-minute survey to help shape the PDI roadmap.

Enable Switch to Next Experience UI toggle button for End-users

Lucky1
Tera Guru

Hello all,

 

Good day!!

Recently we have upgraded to Australia lates version, and I have enabled the below two properties:

glide.ui.polaris.experience

and 

glide.ui.polaris.on_off_user_pref_enabled

 

But as an admin, I can see the "Switch to the Next experience UI" button when I logged in to my instance and I can switch back to the Older UI as well.

 

But I want to make this available to end-users also, because when I impersonate like a user, he is not able to see that option.

 

 

Can someone help me how to do this?

 

 

Regards,

Lucky

10 REPLIES 10

Ankur Bawiskar
Tera Patron

@Lucky1 

if that preference is missing for non-admins then run a script in DEV 1st and then in PROD after verification

var prefName = 'glide.ui.polaris.enabled'; // confirm exact name from your admin user
var defaultValue = 'true'; // or 'false'

var userGr = new GlideRecord('sys_user');
userGr.addActiveQuery();
userGr.query();
while (userGr.next()) {
    var prefGr = new GlideRecord('sys_user_preference');
    prefGr.addQuery('name', prefName);
    prefGr.addQuery('user', userGr.getUniqueValue());
    if (!prefGr.next()) {
        // Create preference for this user
        prefGr.initialize();
        prefGr.name = prefName;
        prefGr.user = userGr.getUniqueValue();
        prefGr.value = defaultValue;
        prefGr.insert();
    }
}

💡 If my response helped, please mark it as correct and close the thread 🔒— this helps future readers find the solution faster! 🙏

Regards,
Ankur
Certified Technical Architect  ||  10x ServiceNow MVP  ||  ServiceNow Community Leader

Hello ANkur,

 

I don't see a table sys_preference.

And also, what if I want to enable this for all itil users?

 

 

 

Regards,

Lucky

@Lucky1 

updated the script, my bad the table name is sys_user_preference

💡 If my response helped, please mark it as correct and close the thread 🔒— this helps future readers find the solution faster! 🙏

Regards,
Ankur
Certified Technical Architect  ||  10x ServiceNow MVP  ||  ServiceNow Community Leader

Rafael Batistot
Kilo Patron

hi @Lucky1 

 

Navigate to User Administration > User Preferences (⁠sys_user_preference.list⁠) :

  •  Open ⁠glide.ui.polaris.use⁠.
  •  Uncheck System (set to ⁠false⁠).
  •  Ensure User is blank (applies to all).
  •  Clear any role restrictions so ⁠snc_internal⁠ users can read/write their own UI preference.

https://www.servicenow.com/community/developer-forum/how-to-make-the-property-glide-ui-polaris-exper...

If this response was helpful, please mark it as Helpful and, if applicable, as Correct.
This helps other users find accurate and useful information more easily