Example #1
0
        private void updateBichao_Load(object sender, EventArgs e)
        {
            this.textBox1.Text = name;
            this.textBox3.Text = time;
            this.textBox9.Text = aichive_no;
            this.textBox4.Text = id_number;
            this.textBox2.Text = bar_code;
            DataTable dtbichao = tjdao.selectXindiantuInfo(aichive_no, bar_code);

            if (dtbichao != null && dtbichao.Rows.Count > 0)
            {
                flag = true;
                this.textBox5.Text  = dtbichao.Rows[0]["XdtResult"].ToString();
                this.textBox6.Text  = dtbichao.Rows[0]["XdtDesc"].ToString();
                this.textBox17.Text = dtbichao.Rows[0]["Ventrate"].ToString();
                this.textBox7.Text  = dtbichao.Rows[0]["PR"].ToString();
                this.textBox12.Text = dtbichao.Rows[0]["QRS"].ToString();
                this.textBox8.Text  = dtbichao.Rows[0]["QT"].ToString();
                this.textBox10.Text = dtbichao.Rows[0]["QTc"].ToString();
                this.textBox11.Text = dtbichao.Rows[0]["P_R_T"].ToString();
                this.textBox13.Text = dtbichao.Rows[0]["DOB"].ToString();
                this.textBox14.Text = dtbichao.Rows[0]["Age"].ToString();
                this.textBox15.Text = dtbichao.Rows[0]["Gen"].ToString();
                this.textBox16.Text = dtbichao.Rows[0]["Dep"].ToString();
                string path = "xdtImg//" + dtbichao.Rows[0]["imageUrl"].ToString();
                if (System.IO.File.Exists(path))
                {
                    xdtPath           = path;
                    pictureBox1.Image = Image.FromFile(path, false);
                }
                string XdtDesc = dtbichao.Rows[0]["XdtDesc"].ToString();
                if (XdtDesc.IndexOf("正常") > -1)
                {
                    this.textBox6.ForeColor = Color.Black;
                }
                else
                {
                    this.textBox6.ForeColor = Color.Red;
                }
            }
            else
            {
                flag = false;
                MessageBox.Show("未查询到数据!");
            }
        }