Getting the current user_name from user object using gs.getUser()

Jamsta1912
Tera Guru

Hi all,

Is there a method for retrieving the user_name directly from gs.getUser() ?

There are a number of methods described here. They cover the sys_id of the user record, and various other fields, but not that actual user_name:

Ihttps://docs.servicenow.com/bundle/jakarta-application-development/page/app-store/dev_portal/API_reference/glideUserScoped/concept/c_GlideUserScopedAPI.html#ariaid-title6

1 ACCEPTED SOLUTION

Mike Patel
Tera Sage

use gs.getUserName()

 

more info - https://www.servicenowguru.com/scripting/user-object-cheat-sheet/

View solution in original post

3 REPLIES 3

Mike Patel
Tera Sage

use gs.getUserName()

 

more info - https://www.servicenowguru.com/scripting/user-object-cheat-sheet/

wowwwwww....lol


Please consider marking my reply as Helpful and/or Accept Solution, if applicable. Thanks!

Allen Andreas
Administrator
Administrator

Hi,

 

Check out this handy document. I use it a for reference quite a bit:

 

https://www.servicenowguru.com/scripting/user-object-cheat-sheet/

 


Please consider marking my reply as Helpful and/or Accept Solution, if applicable. Thanks!