private void btnProcList_Click(object sender, RoutedEventArgs e) { if (_procList != null && _procList.Count > 0) { var wnd = new ProcedureListWnd(_procList); wnd.Owner = Window.GetWindow(this); var answer = wnd.ShowDialog(); if (answer == true) { var item = wnd.SelectedItem; SetCurrentMethod(item); } } }