private void cbObjects_SelectedIndexChanged(object sender, EventArgs e) { switch (cbObjects.Text) { case "Объекты": CompleteForm.dgvDataBaseObjects(this); break; case "Коллекции": CompleteForm.dgvDataBaseCollections(this); break; case "Пользователи": CompleteForm.dgvDataBaseUsers(this); break; default: break; } }
private void DataBaseForm_Load(object sender, System.EventArgs e) { cbObjects.SelectedIndex = 0; CompleteForm.dgvDataBaseObjects(this); }