Example #1
0
        // Method called to load (or reload) the list of packages to the combo box in the
        // packages tab.  Also clears the gridviews and Detail Package panel.
        private void LoadUIforPackages()
        {
            packages = PackageDB.GetAllPackages();

            // First clear the combo box
            comboBoxPkgName.Items.Clear();

            // Next, loop through the list of packages and populate the combo box
            foreach (Package p in packages)
            {
                comboBoxPkgName.Items.Add(p.PackageName);
            }

            // Hide the panels
            panelDetailPkg.Visible = false;
            panelEditPkg.Visible   = false;
            panelAddPkg.Visible    = false;
        }