Exemplo n.º 1
0
        private async void openForm2()
        {
            IngredientList il = await RecipesByCategoryDataProc.LoadMealIngredients(this.ingName);

            Form2 form2 = new Form2();

            form2.setWindow(il.meals[listBox1.SelectedIndex].idMeal);
            form2.Show();
        }
Exemplo n.º 2
0
        private async void recipiesByCategory(string catname)
        {
            RecipesByCategoryList ml = await RecipesByCategoryDataProc.LoadMeal(catname);

            foreach (RecipesByCategoryModel cm in ml.meals)
            {
                listBox1.Items.Add(cm.strMeal);
            }
        }
Exemplo n.º 3
0
        private async void loadList(string name)
        {
            IngredientList il = await RecipesByCategoryDataProc.LoadMealIngredients(name);

            Form6 form6 = new Form6();

            form6.setupRecipesList(il, name);
            form6.Text = "Recipes with main ingredient - " + name;
            form6.Show();
        }
Exemplo n.º 4
0
        private async void loadList()
        {
            IngredientList il = await RecipesByCategoryDataProc.LoadMealIngredients(listBox1.SelectedItem.ToString());

            Form6 form6 = new Form6();

            form6.setupRecipesList(il, listBox1.SelectedItem.ToString()); //calling function that will contain list of recipes
            form6.Text = "Recipes with main ingredient - " + listBox1.SelectedItem.ToString();
            form6.Show();
        }
Exemplo n.º 5
0
        private async void areasWin()
        {
            RecipesByAreaList rbal = await RecipesByCategoryDataProc.LoadMeals(listBox2.SelectedItem.ToString()); // assigning request's result

            Form4 form4 = new Form4();

            form4.setupRecipesList(rbal, listBox2.SelectedItem.ToString());
            form4.Text = listBox2.SelectedItem.ToString() + " Recipes List";
            form4.Show();
        }
Exemplo n.º 6
0
        private async void openForm2()
        {
            //MessageBox.Show(listBox1.SelectedItem.ToString());
            //  MessageBox.Show(ml.meals[listBox1.SelectedIndex].strMeal);
            RecipesByCategoryList ml = await RecipesByCategoryDataProc.LoadMeal(this.catname);

            // MessageBox.Show(ml.meals[listBox1.SelectedIndex].idMeal.ToString());
            Form2 form2 = new Form2();

            form2.setWindow(ml.meals[listBox1.SelectedIndex].idMeal);
            form2.Show();
        }