Print

GetUserData

This function returns specified field value for specified user login. Possible fields to be retrieved values are shown below.

Syntax

GetUserData("userLogin", "fieldName");

Function arguments

  • userLogin – (String) The login of the user for which data is to be retrieved
  • fieldName – (String) The name of the field that is to be retrieved for specified user. Allowed values: [ department | email | firstname | lastname | fullname | email2 | email3 | email4 | language | location | phone | mobile | position | organization | userid | isactive ]

Return value

This function returns String.
Returns value of specified field for specified user or an empty string if there is no value set.

Examples

Example 1:
This will return 'department’ value for user 'rsimmons’.

data = GetUserData("rsimmons", "department");

Example 2:
This will return 'fullname’ value for user 'rsimmons’.

data = GetUserData("rsimmons", "fullname");

Example 3:
This will return 'phone’ value for user stored in [CaseOwner] case field.

data = GetUserData([CaseOwner], "phone");

Example 4:
This will return 'language’ value for user stored in [CaseOwner] case field.

data = GetUserData([CaseOwner], "language");

Example 5:
This will return 1 if user stored in [User] field is active, 0 otherwise.

data = GetUserData([User], "isactive");
Czy artykuł był pomocny?
0 na 5 gwiazdek
5 Stars 0%
4 Stars 0%
3 Stars 0%
2 Stars 0%
1 Stars 0%
5
How can we improve this article?
How Can We Improve This Article?