コード例 #1
0
ファイル: Views.cs プロジェクト: LuisDev99/NuoDB-With-CSharp-
        private void btnDeleteProcedure_Click(object sender, EventArgs e)
        {
            DatabaseHandler dbHandler = new DatabaseHandler();
            string          status    = "";

            if (cmbDeleteViewName.Items.Count != 0)
            {
                status = dbHandler.DeleteView(cmbDeleteViewName.SelectedItem.ToString(), cmbSchemasDelete.SelectedItem.ToString());

                if (status == "Success")
                {
                    MessageBox.Show("View deleted");
                    LoadTablesToCombobox();
                }
                else
                {
                    MessageBox.Show("Something went wrong while deleting the view\nError message: " + status);
                }
            }
        }