removeDictionary() public method

function to remove a dictionary from the database with related slide in the keyword dictionary
public removeDictionary ( string type ) : void
type string the name of the dictionary to remove
return void
        private void cmdRemoveDictionary_Click(object sender, EventArgs e)
        {
            PlanetariumDB_API api = new PlanetariumDB_API();

            if (cmbDictionary.SelectedItem !=null )
            {
                api.removeDictionary(cmbDictionary.SelectedItem.ToString());
                MessageBox.Show("Dictionary deleted");
            }
            reload();
        }
        private void cmdRemoveDictionary_Click(object sender, EventArgs e)
        {
            PlanetariumDB_API api = new PlanetariumDB_API();

            if (cmbDictionary.SelectedIndex != -1)
            {
                dictionary = cmbDictionary.SelectedItem.ToString();
                DialogResult r = MessageBox.Show("Are you sure you want to delete the " + "\"" + dictionary +"\"" +" dictionary?", "Delete Dictionary Confirmation", MessageBoxButtons.YesNo);
                if (r.ToString().Equals("Yes"))
                {
                    api.removeDictionary(cmbDictionary.SelectedItem.ToString());
                    MessageBox.Show("Successfully removed dictionary");
                }

            }
            else
            {
                MessageBox.Show("No dictionary selected - Please select a dictionary to delete");
            }
            reload();
        }