private void editClick(object sender, RoutedEventArgs e)
 {
     if (client == null)
         MessageBox.Show("You must select a client");
     else
     {
         UpdateClient clientUpdateDialog = new UpdateClient(client);
         clientUpdateDialog.ShowDialog();
     }
 }
 private void update_Click(object sender, RoutedEventArgs e)
 {
     Client selected = EditClientt.SelectedItem as Client;
     if (selected == null)
         MessageBox.Show("You must select a client");
     else
     {
         UpdateClient client = new UpdateClient(selected);
         client.ShowDialog();
     }
 }