示例#1
0
        public async void HentdataFraDiskAsync()
        {
            this.Gameliste.Clear();
            StorageFile file = await Localfolder.GetFileAsync(filnavn);

            string jsonText = await FileIO.ReadTextAsync(file);

            Gameliste.indsætJson(jsonText);
        }
示例#2
0
        public async void HentdataFraDiscAsync()
        {
            try
            {
                this.Gameliste.Clear();
                StorageFile file = await localfolder.GetFileAsync(filnavn);

                string jsonText = await FileIO.ReadTextAsync(file);

                Gameliste.indsætJson(jsonText);
            }

            catch
            {
                MessageDialog messageDialog = new MessageDialog("Filnavn højst sandsynligt ændret eller der ikke er gemt");
                await messageDialog.ShowAsync();
            }
        }
示例#3
0
 public void DeleteGame()
 {
     Gameliste.Remove(selectedGame);
 }
示例#4
0
 public void AddNewGame()
 {
     Gameliste.Add(NewGame);
 }