private async void ImageButton_Clicked(object sender, EventArgs e) { AddCriteriaModalPage = new SetCriteriaPage(new Criteria()); AddCriteriaModalPage.Criteria = new Criteria(); AddCriteriaModalPage.CriteriaValidated += this.NewCriteriaValidatedInModal; await Shell.Current.Navigation.PushAsync(AddCriteriaModalPage); }
private async void EditItem_Clicked(object sender, EventArgs e) { var layout = (BindableObject)sender; var item = (CriteriaViewModel)layout.BindingContext; AddCriteriaModalPage = new SetCriteriaPage(item.Criteria); AddCriteriaModalPage.CriteriaValidated += this.NewCriteriaValidatedInModal; await Shell.Current.Navigation.PushAsync(AddCriteriaModalPage); }