protected async override void OnAppearing() { base.OnAppearing(); var status = await Permissions.RequestAsync <Permissions.LocationWhenInUse>(); Location location1 = null; if (status.ToString() == "Denied") { await Application.Current.MainPage.DisplayAlert("Error", "In order to use this, you need to enable your current location!", "OK"); } if (status.ToString() == "Granted") { await model.Init(); } }
protected async override void OnAppearing() { base.OnAppearing(); await model.Init(); SetterI(); }