private async Task Getevent(string teamid) { List <Events> list = await FootballRepo.GetEvents(teamid); Hometeam.Text = list[0].strHomeTeam; Awayteam.Text = list[0].strAwayTeam; }
private async Task Getevent() { list = await FootballRepo.GetEvents(teamid); Hometeam.Text = list[0].strHomeTeam; Awayteam.Text = list[0].strAwayTeam; Shedule.Source = list[0].strthumb; }
private async Task GetInfo() { List <FootbalClub> list = await FootballRepo.GetTeam(Team); list_football = list; Console.WriteLine(list[0].intFormedYear); Console.WriteLine(list[0].strLeague); Console.WriteLine(list[0].strStadium); Console.WriteLine(list[0].strStadiumThumb); Console.WriteLine(list[0].strTeam); NaamTeam.Text = list[0].strTeam.ToUpper(); NaamLeague.Text = list[0].strLeague; NaamStadium.Text = list[0].strStadium; Getevent(list_football[0].idTeam); }
async void BtnBETTING_Clicked(System.Object sender, System.EventArgs e) { Trellocard card = new Trellocard(); try { int Hometeam = Int32.Parse(BETTING_HOMETEAM.Text); int Awayteam = Int32.Parse(BETTING_AWAYTEAM.Text); card.Name = list[0].strHomeTeam + "-" + list[0].strAwayTeam + " = " + BETTING_HOMETEAM.Text + "-" + BETTING_AWAYTEAM.Text; await FootballRepo.AddBetting("5fbf760ec952e73423a16be3", card); Navigation.PushAsync(new MainPage()); } catch (FormatException) { await DisplayAlert("ERROR", "ONLY NUMBERS(1,2,3...)", "OK"); } }
async void Btn_TEAM(System.Object sender, System.EventArgs e) { Team = entTeam.Text; List <Existingteam> list = await FootballRepo.GetExistingteam(Team); if (entTeam.Text == "") { await DisplayAlert("ERROR", "You need to give a teamname", "OK"); } else if (list == null) { await DisplayAlert("ERROR", "Incorrect teamname", "OK"); } else { Navigation.PushAsync(new Overview_Page(Team)); } }