Skip to content

Tools WPF for Pattern MVVM (BaseViewModel & RelayCommand)

Notifications You must be signed in to change notification settings

Mahdikh75/MVVM-Helper

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

// MVVM-Helper

// BaseViewModel (Abstract Class / Method Main ---> SetPropertyChange())

 public class MainViewModel : BaseViewModel
 {
  public int ProgressBarValue
   {
       get { return progress_bar; }
       set { progress_bar = value; SetPropertyChange(); }
   }
 }

// RelayCmmand

 private ICommand close;
 public ICommand Close
 {
     get
     {
         if (close == null)
             close = new RelayCommand(MethodClose, CanMethodClose);
         return close;
     }
 }
 private void MethodClose(object obj)
 {
     (obj as Window).Close();
 }
 private bool CanMethodClose(object obj)
 {
     return true;
 }

About

Tools WPF for Pattern MVVM (BaseViewModel & RelayCommand)

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages