LaunchBrowser Event

Fires before launching a browser with the authorization URL.

Syntax

public event OnLaunchBrowserHandler OnLaunchBrowser;

public delegate void OnLaunchBrowserHandler(object sender, OauthLaunchBrowserEventArgs e);

public class OauthLaunchBrowserEventArgs : EventArgs {
  public string URL { get; set; }
  public string Command { get; set; }
}
Public Event OnLaunchBrowser As OnLaunchBrowserHandler

Public Delegate Sub OnLaunchBrowserHandler(sender As Object, e As OauthLaunchBrowserEventArgs)

Public Class OauthLaunchBrowserEventArgs Inherits EventArgs
  Public Property URL As String
  Public Property Command As String
End Class

Remarks

When the ClientProfile property is set to cfApplication and GetAuthorization is called the component will fire this event with the Command which will be executed by the component. The URL parameter will be the authorization URL which the user will be directed to authenticate.

Within this event you may override the current value of either Command or URL and provide your own value. If Command is set to empty string the component will not attempt to launch the browser and instead you will be responsible for directing the user to the authorization URL specified by AuthorizationURL.

Copyright (c) 2022 /n software inc. - All rights reserved.
Cloud Mail 2020 .NET Edition - Version 20.0 [Build 8308]