I am trying to access parent window from user control.
userControl1 uc1 = new userControl1(); mainGrid.Children.Add(uc1);
through this co
This gets the root level window:
Window parentWindow = Application.Current.MainWindow
or the immediate parent window
Window parentWindow = Window.GetWindow(this);