B B

B B

  • NA
  • 100
  • 1.8k

How to open a new window or user control through command

Oct 18 2018 4:32 AM
Hi,
 
In my WPF application, I have a parent window Main.xaml where i have a button. On click of button i want to open a new window ChildWindow.xaml through command (and not through click event in code behind) 
when the child form open i want to disable the Main.xaml window so that user cannot click anything on it.
 
i need it through MVVM so creating  ChildWindow instance in the viewmodel i am not looking for. Can anybody please help me out.
 
 
Thanks. 

Answers (1)