Inheritance: System.Windows.Forms.Form
Ejemplo n.º 1
0
 /// <summary>
 /// Gets the session with browser
 /// </summary>
 /// <returns>SessionInfo with info about user session. Null - if login failed</returns>
 public SessionInfo GetSession()
 {
     this.OnLog("Creating login wnd...");
     BrowserAuthorization wnd = new BrowserAuthorization();
     wnd.Permissions = this.Permissions;
     wnd.AppId = this.AppId;
     wnd.ShowDialog();
     if (wnd.LoginInfoReceived)
     {
         this.OnLog("Authorization successed!");
         return wnd.si;
     }
     else
     {
         this.OnLog("Authorization failed!");
         return null;
     }
 }
Ejemplo n.º 2
0
        /// <summary>
        /// Gets the session with browser
        /// </summary>
        /// <returns>SessionInfo with info about user session. Null - if login failed</returns>
        public SessionInfo GetSession()
        {
            this.OnLog("Creating login wnd...");
            BrowserAuthorization wnd = new BrowserAuthorization();

            wnd.Permissions = this.Permissions;
            wnd.AppId       = this.AppId;
            wnd.ShowDialog();
            if (wnd.LoginInfoReceived)
            {
                this.OnLog("Authorization successed!");
                return(wnd.si);
            }
            else
            {
                this.OnLog("Authorization failed!");
                return(null);
            }
        }