Question

I have a necessity of creating RadWindow.Alert and I am seeing this radwindow gets hidden when I switched between apps or press Tab+Alt .What is solution?

Était-ce utile?

La solution

var topWindow = Application.Current.Windows.Cast<Window>().FirstOrDefault(win => win.Topmost);

Application.Current.Dispatcher.BeginInvoke(new Action(() => RadWindow.Alert(new DialogParameters
                                                                           {
                                                                               Content = "write your comment",
                                                                               Header = "type header here",
                                                                               DialogStartupLocation = WindowStartupLocation.Manual,
                                                                               Left = targetX,
                                                                               Top = targetY,
                                                                               Owner = topWindow ?? Application.Current.MainWindow
                                                                           })));
Licencié sous: CC-BY-SA avec attribution
Non affilié à StackOverflow
scroll top