private void searchPB_click(object sender, EventArgs e) { addPatientPanel.Hide(); informPanel.Hide(); medicalPanel.Hide(); addDetailPanel.Hide(); searchPanel.Show(); addPatientPB.BorderStyle = BorderStyle.None; medicalDetailPB.BorderStyle = BorderStyle.None; displayPB.BorderStyle = BorderStyle.None; searchPB.BorderStyle = BorderStyle.Fixed3D; DatabaseConnertor databaseConnertor = new DatabaseConnertor(); databaseConnertor.connect(); addPatientHandler addPatientHandler = new addPatientHandler(); patientDAT.DataSource = addPatientHandler.getAllPatient(databaseConnertor.getconn()); DatabaseConnertor database = new DatabaseConnertor(); databaseConnertor.connect(); pmdetailsHandler pmdetailsHandler = new pmdetailsHandler(); dataGridView1.DataSource = pmdetailsHandler.getAlldetails(databaseConnertor.getconn()); }
private void History_Load(object sender, EventArgs e) { DatabaseConnertor database = new DatabaseConnertor(); database.connect(); realtimeHandler realtimeHandler = new realtimeHandler(); dgvHistory.DataSource = realtimeHandler.getAlldetails(database.getconn()); database.connect(); addPatientHandler addPatientHandler = new addPatientHandler(); dgvPatient.DataSource = addPatientHandler.getAllPatient(database.getconn()); }