private void tampilPeg(string ID_PEG) { cDatabase db = new cDatabase(); cQuery qr = new cQuery(); DataTable dt = db.selectData(qr.qSelectNamaRfidPegByIdPeg(ID_PEG), '4');//4 = konek ke 10.0.1.64 db payroll_web if (dt.Rows.Count != 0) { foreach (DataRow rowMhs in dt.Rows) { txt_nik.Text = rowMhs["nik"].ToString(); txt_nama.Text = rowMhs["nama"].ToString(); txtRfid.Text = rowMhs["rfid"].ToString(); lbIdPegawai.Text = rowMhs["id_pegawai"].ToString(); } } dt.Clear(); dt.Dispose(); }