ESRI.ArcGIS.Client.Toolkit.SignInDialog.GenerateNetworkCredential C# (CSharp) Method

GenerateNetworkCredential() private method

private GenerateNetworkCredential ( ) : void
return void
		private void GenerateNetworkCredential()
		{
			if (!IsReady)
				return;

			_callbackHasBeenCalled = true; // Avoid that IsActive = false calls the callback with Cancel exception
			IsActive = false;
			var credential = new IdentityManager.Credential {Credentials = new NetworkCredential(UserName, Password)};
			if (Callback != null)
				Callback(credential, null);
		}
		#endregion

Usage Example

Ejemplo n.º 1
0
            public void Execute(object parameter)
            {
#if SILVERLIGHT
                _signInDialog.GenerateToken();
#else
                if (_signInDialog.AuthenticationType == IdentityManager.AuthenticationType.Token)
                {
                    _signInDialog.GenerateToken();
                }
                else
                {
                    _signInDialog.GenerateNetworkCredential();
                }
#endif
            }