private async void Refresh() { NetService net = new NetService(); List <Dialog> Dialogs = new List <Dialog> { }; IEnumerable <Dialog> dialogs = await net.GetDialogs(ReqO); foreach (Dialog d in dialogs) { Dialogs.Add(d); } }
private async void User_Enter(object sender, EventArgs e) { NetService net = new NetService(); request_objs ReqO = new request_objs(loginEntry.Text, passwordEntry.Text); List <Dialog> Dialogs = new List <Dialog> { }; IEnumerable <Dialog> dialogs = await net.GetDialogs(ReqO); foreach (Dialog d in dialogs) { Dialogs.Add(d); } await Navigation.PushAsync(new MainPage(ReqO, Dialogs)); }