private void Button_Browse_Click(object sender, RoutedEventArgs e) { var browseComputersDialog = new BrowseComputers { ClientsDictionary = ClientsDictionary, listBoxOut = listBoxComputers }; browseComputersDialog.ShowDialog(); }
private void buttonBrowseComputers_Click(object sender, RoutedEventArgs e) { var browseComputersDialog = new BrowseComputers(); browseComputersDialog.clients = clients; browseComputersDialog.listBoxOut = listBoxTargetComputers; browseComputersDialog.ShowDialog(); if (listBoxTargetComputers.Items.Count != 0) { labelMachineGroupContent.Content = (browseComputersDialog.treeView.SelectedItem as TreeViewItem).Header; } else { labelMachineGroupContent.Content = "NONE"; } labelNumberOfMachines.Content = "Number Of PCs: " + listBoxTargetComputers.Items.Count; }