Example #1
0
        private async void ConnectButton_ClickAsync(object sender, EventArgs e)
        {
            try
            {
                ConfiguredEndpoint endpoint = (ConfiguredEndpoint)ServerUrlTextBox.Tag;

                if (endpoint == null)
                {
                    return;
                }

                if (endpoint.Description.Server.ApplicationUri == endpoint.Description.EndpointUrl)
                {
                    m_server.Connect(endpoint.Description.EndpointUrl);
                }
                else
                {
                    m_server.Connect(endpoint);
                }

                ServerStatusPanel.Initialize(m_server);
                await CertificatePanel.Initialize(m_configuration, m_gds, m_server, m_registeredApplication, false);
            }
            catch (Exception exception)
            {
                ExceptionDlg.Show(this.Text, exception);
            }
        }
Example #2
0
 private void Server_ConnectionStatusChanged(object sender, EventArgs e)
 {
     if (Object.ReferenceEquals(sender, m_server))
     {
         if (m_server.IsConnected)
         {
             ServerStatusPanel.Initialize(m_server);
         }
         else
         {
             ServerStatusPanel.Initialize(null);
         }
     }
 }
Example #3
0
 private void DisconnectButton_Click(object sender, EventArgs e)
 {
     try
     {
         if (m_server.IsConnected)
         {
             m_server.Disconnect();
             UpdateStatus(true, DateTime.UtcNow, "Disconnected {0}", m_server.Endpoint);
             ServerStatusPanel.Initialize(null);
         }
     }
     catch (Exception exception)
     {
         ExceptionDlg.Show(this.Text, exception);
     }
 }