Skip to main content
Version: 7.9

system.security.getUsername

This function is used in Python Scripting.

Description

Returns the currently logged-in username.

Client Permission Restrictions

This scripting function has no Client Permission restrictions.

Syntax

system.security.getUsername()

Parameters

None

Returns

String - The current user name.

Scope

All

Code Examples

Example #1
# This code would run on a startup script and does special logic based upon who was logging in
name = system.security.getUsername()
if name == 'Bob':
system.nav.openWindow("BobsHomepage")
else:
system.nav.openWindow("NormalHomepage")