In a WPF window, how do I know if it is opened?
My goal to open only 1 instance of the window at the time.
So, my pseudo code in the parent window is:
public bool IsWindowOpen(string name = "") where T : Window { return Application.Current.Windows.OfType().Any(w => w.GetType().Name.Equals(name)); }