I'm trying to put a button in a radwindow that I create on the fly from code. But it's not working. the button is "born dead". When I click on it I don't even see the visual effect of the click. Nor does it execute the click event. My code is as follows. What is wrong?
Thanks, Gary
Image BigImage = new Image();
bmp.SetSource(new System.IO.MemoryStream(myPictureAndNotesClass.Picture));
BigImage.Source = bmp;
ToolTipService.SetToolTip(BigImage, myPictureAndNotesClass.Notes);
RadWindow BigPicWindow = new RadWindow();
StackPanel mysp = new StackPanel();
mysp.Orientation = Orientation.Horizontal;
Button fsbutton = new Button();
fsbutton.Click += new RoutedEventHandler(fsbutton_Click);
fsbutton.Content = "Full Screen";
TextBlock textblock = new TextBlock() { Text = " " + myPictureAndNotesClass.Notes };
mysp.Children.Add(fsbutton);
mysp.Children.Add(textblock);
BigPicWindow.Header = mysp;
BigPicWindow.Content = BigImage;
BigPicWindow.Show();
Thanks, Gary
Image BigImage = new Image();
bmp.SetSource(new System.IO.MemoryStream(myPictureAndNotesClass.Picture));
BigImage.Source = bmp;
ToolTipService.SetToolTip(BigImage, myPictureAndNotesClass.Notes);
RadWindow BigPicWindow = new RadWindow();
StackPanel mysp = new StackPanel();
mysp.Orientation = Orientation.Horizontal;
Button fsbutton = new Button();
fsbutton.Click += new RoutedEventHandler(fsbutton_Click);
fsbutton.Content = "Full Screen";
TextBlock textblock = new TextBlock() { Text = " " + myPictureAndNotesClass.Notes };
mysp.Children.Add(fsbutton);
mysp.Children.Add(textblock);
BigPicWindow.Header = mysp;
BigPicWindow.Content = BigImage;
BigPicWindow.Show();