private void fillgidview() { try { cnn.Open(); string sqlcommand = " select OPD_NO as [OPD No],Patientname as [Pateint Name],Age,VisitDate as [visit Date],Department,Consultent_Doctor from OPD_table where Status_pet='Checked In' and Consultent_Doctor='" + label5.Text + "'"; SqlDataAdapter adap = new SqlDataAdapter(sqlcommand, cnn); DataTable dt = new DataTable(); adap.Fill(dt); this.dataGridView1.DataSource = dt; cnn.Close(); } catch (Exception ex) { MessageBox.Show(ex.ToString()); } }
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)