WPF- How to use MessageBox in MVVM

Viewed 21

I want to call the MessageBox provided by WPF in the MVVM pattern ViewModel file. If it is in MainWindow.xaml.cs, I know I can use MessageBox.Show() directly, but using it in VM is against the MVVM principle.

0 Answers
Related