// logic for the full inventory button
        private void Full_Inventory_Button(object sender, RoutedEventArgs e)
        {
            // Sets the global index to 0 so it can start at the beginning of the list
            Global.SetIndex(0);
            // Creates an instance of the iterative update window
            Window iterativeUpdateWindow = new Iterative_Update_Window();

            // Shows the instance of the iterative update window
            iterativeUpdateWindow.Show();
            // Closes the main window
            this.Close();
        }
        private void Update_Next(object sender, RoutedEventArgs e)
        {
            // Stores the inventory
            inventoryList[itemIndex] = tempInventoryItem;
            InventoryList.PercentageFillerSingle(inventoryList, itemIndex);
            // Increments to the next item in the inventory list
            itemIndex++;

            // If we're at the end of the inventory list
            if (itemIndex > inventoryList.Count - 1) // greater than total number of items in list, then at end of list
            {
                // reset the global item index
                Global.SetIndex(-1);

                using (SQLiteConnection conn = new SQLiteConnection(App.databasePath))
                {
                    conn.CreateTable <Inventory>();

                    Inventory m = (from p in conn.Table <Inventory>()
                                   where p.Product == ProductNameTextBlock.Text
                                   select p).FirstOrDefault();
                    if (m != null)
                    {
                        m.Actual = Convert.ToInt32(UpdateIdealTextBox.Text);
                        conn.Update(m);
                        //Console.WriteLine("This ran");
                    }
                }

                // create a new instance of the main window
                Window mainWindow = new MainWindow();
                // show the instance of the main window
                mainWindow.Show();
                // close the full iterative update window
                this.Close();
            }
            // if we're not at the end yet
            else
            {
                // set the global item index to the incremented index
                Global.SetIndex(itemIndex);

                using (SQLiteConnection conn = new SQLiteConnection(App.databasePath))
                {
                    conn.CreateTable <Inventory>();

                    Inventory m = (from p in conn.Table <Inventory>()
                                   where p.Product == ProductNameTextBlock.Text
                                   select p).FirstOrDefault();
                    if (m != null)
                    {
                        m.Actual = Convert.ToInt32(UpdateIdealTextBox.Text);
                        conn.Update(m);
                    }
                }

                // create a new instance of the iterative update window
                Window iterativeUpdateWindow = new Iterative_Update_Window();
                // show the instance of the iterative update window
                iterativeUpdateWindow.Show();
                // close the previous instance of the iterative update window
                this.Close();
            }
        }