Ejemplo n.º 1
0
        private void ConnectCore()
        {
            _form = new TestForm();
            _form.Show();
            _ax = _form.RdpControl;
            _ax.Server = _context.Server.Name;
            _ax.Domain = _context.Server.Domain;
            _ax.UserName = _context.Server.Username;
            _ax.AdvancedSettings8.ClearTextPassword = _context.Server.Password;
            _ax.OnConnected += delegate { _connectedEvent.Set(); };
            _ax.OnDisconnected += AxOnDisconnected;
            _ax.Connect();

            // You need a message loop or else the RDP client control will never connect.
            // That's why we run the form on a separate thread.
            Application.Run(_form);
            _form.Dispose();
        }
Ejemplo n.º 2
0
        private void ConnectCore()
        {
            _form = new TestForm();
            _form.Show();
            _ax          = _form.RdpControl;
            _ax.Server   = _context.Server.Name;
            _ax.Domain   = _context.Server.Domain;
            _ax.UserName = _context.Server.Username;
            _ax.AdvancedSettings8.ClearTextPassword = _context.Server.Password;
            _ax.OnConnected    += delegate { _connectedEvent.Set(); };
            _ax.OnDisconnected += AxOnDisconnected;
            _ax.Connect();

            // You need a message loop or else the RDP client control will never connect.
            // That's why we run the form on a separate thread.
            Application.Run(_form);
            _form.Dispose();
        }