private void FillEmpPFUANDetailData1() { objHRInfo = new HRInfo(); DataSet ds = new DataSet(); try { ds = objHRInfo.GetEmpPFUANDetailData1(txtEcodeSearch.Text); } catch (Exception ex) { MessageBox.Show(ex.ToString()); } finally { objHRInfo = null; } if (ds != null) { if (ds.Tables[0].Rows.Count > 0) { flagUdate = true; txtUAN.Text = ds.Tables[0].Rows[0]["HAUM_UAN_NO"].ToString(); if (ds.Tables[0].Rows[0]["HAUM_ADDR_PRES_HNO"].ToString().Length != 0) { dt = ds.Tables[0]; txtEmpHNo.ReadOnly = true; txtEmpLandMark.ReadOnly = true; txtEmpVill.ReadOnly = true; txtEmpMandal.ReadOnly = true; txtEmpDistricit.ReadOnly = true; txtEmpState.ReadOnly = true; txtEmpPin.ReadOnly = true; txtEmpPh.ReadOnly = true; txtEmpHNo.Text = ds.Tables[0].Rows[0]["HAUM_ADDR_PRES_HNO"].ToString(); txtEmpLandMark.Text = ds.Tables[0].Rows[0]["HAUM_ADDR_PRES_LANDMARK"].ToString(); txtEmpVill.Text = ds.Tables[0].Rows[0]["HAUM_ADDR_PRES_VILLAGE"].ToString(); txtEmpMandal.Text = ds.Tables[0].Rows[0]["HAUM_ADDR_PRES_MANDAL"].ToString(); txtEmpDistricit.Text = ds.Tables[0].Rows[0]["HAUM_ADDR_PRES_DISTRICT"].ToString(); txtEmpState.Text = ds.Tables[0].Rows[0]["HAUM_ADDR_PRES_STATE"].ToString(); txtEmpPin.Text = ds.Tables[0].Rows[0]["HAUM_ADDR_PRES_PIN"].ToString(); txtEmpPh.Text = ds.Tables[0].Rows[0]["HAUM_ADDR_PRES_PHNO"].ToString(); } else { txtEmpHNo.ReadOnly = false; txtEmpLandMark.ReadOnly = false; txtEmpVill.ReadOnly = false; txtEmpMandal.ReadOnly = false; txtEmpDistricit.ReadOnly = false; txtEmpState.ReadOnly = false; txtEmpPin.ReadOnly = false; txtEmpPh.ReadOnly = false; } if (ds.Tables[0].Rows[0]["HAUM_SIG1"].ToString() != "") { GetImage((byte[])ds.Tables[0].Rows[0]["HAUM_SIG1"], "SIG1"); } if (ds.Tables[0].Rows[0]["HAUM_SIG2"].ToString() != "") { GetImage((byte[])ds.Tables[0].Rows[0]["HAUM_SIG2"], "SIG2"); } if (ds.Tables[0].Rows[0]["HAUM_SIG3"].ToString() != "") { GetImage((byte[])ds.Tables[0].Rows[0]["HAUM_SIG3"], "SIG3"); } FillEmpPFUANDetailData2(""); } else { //txtUAN.Text = ""; //txtEmpHNo.Text = ""; //txtEmpLandMark.Text = ""; //txtEmpVill.Text = ""; //txtEmpMandal.Text = ""; //txtEmpDistricit.Text = ""; //txtEmpState.Text = ""; //txtEmpPin.Text = ""; //txtEmpPh.Text = ""; txtEmpHNo.ReadOnly = false; txtEmpLandMark.ReadOnly = false; txtEmpVill.ReadOnly = false; txtEmpMandal.ReadOnly = false; txtEmpDistricit.ReadOnly = false; txtEmpState.ReadOnly = false; txtEmpPin.ReadOnly = false; txtEmpPh.ReadOnly = false; } } ds = null; }