Ankur Bawiskar
Tera Patron

@vijayvasant 

try this

(function executeRule(current, previous /null when async*/) {

// Add your code here
var gr = new GlideRecord("sys_user_grmember");
gr.addQuery("user", gs.getUserID());
gr.addQuery("group.sys_id", "IN", gs.getProperty('xoc.incident.show_exec_notification'));
gr.setLimit(1);
gr.query();
g_scratchpad.isMember = gr.hasNext().toString();

}(current, previous);

onLoad client script

function onLoad() {
    if (g_scratchpad.isMember == 'true')
        g_form.setSectionDisplay('executive_notification', false);
}

If my response helped please mark it correct and close the thread so that it benefits future readers.

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