private async void GetNodeList(object sender, RoutedEventArgs e) { TransactionProtocol protocol = new TransactionProtocol(); string[] nodeList = await protocol.GetAllNode(); if (nodeList[0] != "") { RadioButton originalRadioButton = new RadioButton() { Content = XmlManager.GetHttp(), IsChecked = true, }; originalRadioButton.Checked += OnSelect; spNodeList.Children.Add(originalRadioButton); for (int index = 0; index < nodeList.Length; index++) { RadioButton radioButton = new RadioButton(); radioButton.Content = $"{nodeList[index]}/"; radioButton.Checked += OnSelect; spNodeList.Children.Add(radioButton); } } else { MessageBox.Show("Timeout", "Error"); } }
public TransactionProtocol() { URL = XmlManager.GetHttp(); Response = ""; }
public SettingWindow() { InitializeComponent(); txtHostname.Text = XmlManager.GetHttp(); txtDefaultName.Text = "Default URL: http://localhost:3000/"; }