private void SelectGdsButton_Click(object sender, EventArgs e) { m_gds.AdminCredentials = null; m_gds.Disconnect(); m_gdsConfigured = false; UpdateGdsStatus(true, DateTime.UtcNow, "Disconnected"); string uri = new SelectGdsDialog().ShowDialog(null, m_gds, m_gds.GetDefaultGdsUrls(m_lds)); if (uri != null) { m_configuration.GlobalDiscoveryServerUrl = m_gds.EndpointUrl; m_gdsConfigured = true; UpdateGdsStatus(false, DateTime.UtcNow, "Connected"); } }
private void RegistrationButton_Click(object sender, EventArgs e) { try { if (!m_gdsConfigured) { string uri = new SelectGdsDialog().ShowDialog(null, m_gds, m_gds.GetDefaultGdsUrls(m_lds)); if (uri != null) { m_configuration.GlobalDiscoveryServerUrl = m_gds.EndpointUrl; m_gdsConfigured = true; SelectGdsButton.Visible = true; } } ShowPanel(Panel.Registration); } catch (Exception ex) { Opc.Ua.Client.Controls.ExceptionDlg.Show(Text, ex); } }