private void g_DeleteRequested(object sender, RoutedEventArgs e) { stackPanel1.Children.Remove((sender as UIElement)); }