public BandViewModel()
 {
     Bandliste      = new Model.BandList();
     selectedBand   = new Model.Band();
     AddBandCommand = new AddBandCommand(AddNewBand);
     NewBand        = new Model.Band();
     //AddBandCommand = new RelayCommand(AddNewBand);
 }
Esempio n. 2
0
        /// <summary>
        /// default constructor
        /// </summary>
        public BandViewModel()
        {
            Tid               = new DateTime();
            Bandliste         = new BandList();
            selectedBand      = new Band();
            AddBandCommand    = new AddBandCommand(AddNewBand);
            DeleteBandCommand = new RelayCommand(DeleteBand);
            SaveBandCommand   = new RelayCommand(GemDataTilDiskAsync);

            //bruger en anonym metode i min relaycommand
            DeleteAllBandCommand = new RelayCommand(() => this.Bandliste.Clear());
            HentDataCommand      = new RelayCommand(HentdataFraDiskAsync);
            localfolder          = ApplicationData.Current.LocalFolder;
        }