"Parent Class"
<window x:class="X.Parent" xmlns:x="#unknown">
..
>
<grid>
<local:childusercontrolc xmlns:local="#unknown"></local:childusercontrolc>
</grid>
</window>
"Clild Class"
<usercontrol x:class="X.ChildUserControlC" xmlns:x="#unknown">
...>
<grid>
<button content="Cancel" click="cancel">
</button></grid>
</usercontrol>
private void Cancel(object sender, RoutedEventArgs e)
{
Window parentWindow = Window.GetWindow(this);
parentWindow.Close();
}