system.user.getUser
Description
Looks up a specific user in a user source, by username. The full User object is returned. See the docs for system.user.getUsers for more information about the User object type.
Syntax
system.user. getUser( userSource, username )
-
Parameters
String userSource - The name of the user source to search for the user in.
String username - The username of the user to search for.
-
Returns
User - A User object.
-
Scope
All
Code Examples
Code Snippet
#This example will print the first and last name of the current user using the default datasource:
userName
=
system.security.getUsername()
user
=
system.user.getUser("", userName)
print
user.get(user.FirstName)
+
" "
+
user.get(user.LastName)