Type: BCS.Sym3.Operator.Runtime.IAuthenticationService

Gets access to the authentication service

Properties


CurrentUserName

  • Description: Gets set the current user name. This can be empty if no user logged in.
  • Type: String
  • Access: Read and Write
  • Example:
var user = Client.Authentication.CurrentUserName;

Methods


DisplayLoginDialog

Pops up the login form

  • Example:
This example shows you how to use this method:

            Client.Authentication.DisplayLoginDialog();
            

DisplayLoginDialog(System.Boolean,System.UInt32,System.UInt32)

Pops up the login form

  • Parameters:
    • atMousePosition: if true the form will pops up at mouse position
    • x: if atMousePosition=false, the form will popups at position x, y
    • y: if atMousePosition=false, the form will popups at position x, y
  • Example:
This example shows you how to use this method:

            Client.Authentication.DisplayLoginDialog(false, 200, 100);
            

Logoff

Logoff the current user

  • Example:
This example shows you how to use this method:

            Client.Authentication.LogOff();
            

Events

UserChanged This event occurs after the current user changed.

  • Example:
This example shows you how to subscribe to this event

            //---- JAVASCRIPT:
            Client.Authentication.add_UserChanged(OnUserChanged);
            ...
            function OnUserChanged(){
                print("New user is: " + Client.Authentication.CurrentUserName);
            }