[WPF] 새로운 창 띄우기 (버튼 클릭 시)
·
c#/WPF
1. Views폴더에 SecondView.xaml 생성 2. SecondViewModel 생성 및 ProgressValue 정의 3. SecondView.xaml 의 progressBar에 Value에 Binding 4. MainViewModel에 SecondShow 생성 (ICommand) 5.MainWindow.xaml 에 버튼 생성 및 command binding
[WPF] MVVM 패턴 적용해보기 (기초, 초급, 쉬움)
·
c#/WPF
ViewModels 폴더 생성 -> MainViewModel.cs 생성하기 - INotifyPropertychanged 를 상속받아야 함 : 값이 변경되면 전달하기 위해 - progressValue 값이 변한 것을 View에 나타낼것임 - INotifyPropertychanged 인터페이스 구현해주기 public event PropertyChangedEventHandler PropertyChanged; // This method is called by the Set accessor of each property. // The CallerMemberName attribute that is applied to the optional propertyName // parameter causes the prope..