Skip to main content
Version: 8.3 Beta 🚧

system.vision.getUsername

Backwards Compatibility

This function replaces system.security.getUsername. Any scripts containing Vision Client scoped functions that were replaced with system.vision syntax will still work to maintain backwards compatibility. Only the system.vision variations will appear in the Script Editor's autocomplete popup.

This function is used in Python Scripting.

Description​

Returns the current username logged in.

Client Permission Restrictions​

This scripting function has no Client Permission restrictions.

Syntax​

system.vision.getUsername()

Parameters​

Nothing

Returns​

String - The current username.

Scope​

Vision Client

Code Examples​

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