示例#1
0
        private void categoriaClicked(object sender, EventArgs e)
        {
            CrearCategoriaPage myHomePage = new CrearCategoriaPage();

            NavigationPage.SetHasNavigationBar(myHomePage, false);
            Navigation.PushModalAsync(myHomePage);
        }
示例#2
0
        public async void Save_Clicked(object sender, EventArgs e)
        {
            Categoria categoriar = new Categoria();

            categoriar.Categoria1 = Categoria.Text;
            Repositorio repo = new Repositorio();

            try
            {
                Categoria categoria = repo.postCategoria(categoriar).Result;
                Dialogs.ShowLoading("Categoria Creada");
                await Task.Delay(2000);

                Dialogs.HideLoading();
                CrearCategoriaPage myHomePage = new CrearCategoriaPage();
                NavigationPage.SetHasNavigationBar(myHomePage, false);
                await Navigation.PushModalAsync(myHomePage);
            }

            catch (Exception ex)
            {
                await DisplayAlert("Registrarse Error", ex.Message, "Gracias");
            }
        }