Which one of the following is true for GlideUser (g_user) methods?
A . Can be used in Client Scripts and UI Policies only
B . Can be used in Business Rules only
C . Can be used in Client Scripts, UI Policies, and UI Actions
D . Can be used in Business Rules, and Scripts Includes
Answer: C
Explanation:
The following is true for GlideUser (g_user) methods:
Can be used in Client Scripts, UI Policies, and UI Actions. This is true because GlideUser (g_user) methods are part of the client-side scripting APIs that provide information about the current user and the user’s preferences. Client Scripts, UI Policies, and UI Actions are all types of client-side scripts that run in the web browser and manipulate the user interface. The following are not true for GlideUser (g_user) methods:
Can be used in Client Scripts and UI Policies only. This is false because GlideUser (g_user) methods can also be used in UI Actions, which are another type of client-side scripts that can be triggered by a user’s click on a button, link, or choice.
Can be used in Business Rules only. This is false because GlideUser (g_user) methods cannot be used in Business Rules, which are server-side scripts that run on the ServiceNow platform and manipulate the database. Business Rules use a different API to access the current user information, which is GlideSystem (gs).
Can be used in Business Rules, and Scripts Includes. This is false because GlideUser (g_user) methods cannot be used in Business Rules or Script Includes, which are both server-side scripts. Script Includes are reusable units of code that can be called from any server-side script. Script Includes also use GlideSystem (gs) to access the current user information.
Reference: Client-Side Scripting APIs, GlideUser, Business Rules, Script Includes
Reference: https://developer.servicenow.com/dev.do#!/reference/api/newyork/client/c_GlideUserAPI
Latest CAD Dumps Valid Version with 60 Q&As
Latest And Valid Q&A | Instant Download | Once Fail, Full Refund