private void rec_remark_TextChanged(object sender, EventArgs e) { TextBox txtBox = (TextBox)sender; trn_doctor_aviation DoctorAviation = bsDoctorAviation.OfType <trn_doctor_aviation>().FirstOrDefault(); if (DoctorAviation != null) { DoctorAviation.trav_rec_remark = txtBox.Text; } }
private void ShowLabResult(int?tpr_id) { try { using (InhCheckupDataContext dbc = new InhCheckupDataContext()) { trn_doctor_aviation DoctorAviation = bsDoctorAviation.OfType <trn_doctor_aviation>().FirstOrDefault(); var labResult = dbc.sp_med_exm_report(tpr_id).FirstOrDefault(); if (labResult != null) { txtBlgr.Text = labResult.A0200; txtRh.Text = labResult.L0030; txtHb.Text = labResult.A0001; txtVpc.Text = ""; txtFBS.Text = labResult.C0180; txtChol.Text = labResult.C0130; txtTrig.Text = labResult.C0140; txtHDL.Text = labResult.C0150; txtLDL.Text = labResult.C0159; txtSGOT.Text = labResult.C0040; txtSGPT.Text = labResult.C0030; txtAlk.Text = labResult.C0010; txtBun.Text = labResult.C0080; txtCreat.Text = labResult.C0070; txtUric.Text = labResult.C0320; txtVDRL.Text = labResult.P1015; //txtHIV.Text = labResult.X0012 == null ? "Not Test" : "Tested"; txtHIV.Text = labResult.X0012; txtHBsAg.Text = labResult.N7014; txtSugar.Text = labResult.D1105; txtAlbumin.Text = labResult.C0060; txtMicro.Text = labResult.E0020; if (labResult.ecg_normal == null && labResult.ecg_abnormal == null) { radioButton78.Checked = false; radioButton79.Checked = false; } else if (labResult.ecg_normal.Length != 0) { radioButton78.Checked = true; } else if (labResult.ecg_normal.Length != 0) { radioButton79.Checked = true; } if (labResult.chest_x_normal == null && labResult.chest_x_abnormal == null) { radioButton80.Checked = false; radioButton81.Checked = false; } else if (labResult.chest_x_normal.Length != 0) { radioButton80.Checked = true; } else if (labResult.chest_x_normal.Length != 0) { radioButton81.Checked = true; } } } } catch (Exception ex) { Program.MessageError(this.Name, "ShowLabResult", ex, false); } }