public static bool InsertAccessXCG(UpLoadDataForXCG obj, out string err)
        {
            err = "";
            bool flag = false;

            try
            {
                string sql = string.Format(@"insert into zkhw_tj_xcg(bar_code,WBC,RBC,PCT,PLT,HGB,HCT,MCV,MCH,MCHC,RDWCV,RDWSD,
                                             MONO,MONOP,GRAN,GRANP,NEUT,NEUTP,EO,EOP,BASO,BASOP,LYM,
                                            LYMP,MPV,PDW,MXD,MXDP,PLCR,OTHERS,createtime)values('{0}','{1}','{2}','{3}','{4}'
                                            ,'{5}','{6}','{7}','{8}','{9}','{10}','{11}','{12}','{13}','{14}','{15}','{16}','{17}','{18}','{19}'
                                            ,'{20}','{21}','{22}','{23}','{24}','{25}','{26}','{27}','{28}','{29}','{30}')",
                                           obj.bar_code, obj.WBC, obj.RBC, obj.PCT, obj.PLT, obj.HGB, obj.HCT, obj.MCV, obj.MCH, obj.MCHC,
                                           obj.RDW_CV, obj.RDW_SD, obj.MONO, obj.MONOP, obj.GRAN, obj.GRANP, obj.NEUT, obj.NEUTP, obj.EO, obj.EOP,
                                           obj.BASO, obj.BASOP, obj.LYM, obj.LYMP, obj.MPV, obj.PDW, obj.MXD, obj.MXDP, obj.PLCR,
                                           obj.OTHERS, obj.createtime);
                int ret = DbHelperAccess.ExecuteSql(sql);
                if (ret > 0)
                {
                    flag = true;
                }
            }
            catch (Exception e)
            {
                err = e.Message;
            }
            return(flag);
        }
        public static bool InsertAccessSh(UpLoadDataForSH obj, out string err)
        {
            bool flag = false;

            err = "";
            try
            {
                string sql = string.Format(@"insert into zkhw_tj_sh(bar_code,ALT,AST,TBIL,DBIL,CREA,UREA,GLU,TG,CHO,HDLC,LDLC,ALB,UA,HCY,AFP,
                                      CEA,Ka,Na,TP,ALP,GGT,CHE,TBA,APOA1,APOB,CK,CKMB,LDHL,HBDH,aAMY,createtime)values('{0}','{1}','{2}'
                                      ,'{3}','{4}','{5}','{6}','{7}','{8}','{9}','{10}','{11}','{12}','{13}','{14}','{15}','{16}','{17}','{18}','{19}'
                                      ,'{20}','{21}','{22}','{23}','{24}','{25}','{26}','{27}','{28}','{29}','{30}','{31}')",
                                           obj.bar_code, obj.ALT, obj.AST, obj.TBIL, obj.DBIL, obj.CREA, obj.UREA, obj.GLU, obj.TG, obj.CHO, obj.HDL_C,
                                           obj.LDL_C, obj.ALB, obj.UA, obj.HCY, obj.AFP, obj.CEA, obj.Ka, obj.Na, obj.TP, obj.ALP, obj.GGT, obj.CHE, obj.TBA,
                                           obj.APOA1, obj.APOB, obj.CK, obj.CKMB, obj.LDHL, obj.HBDH, obj.aAMY, obj.createtime);
                int ret = DbHelperAccess.ExecuteSql(sql);
                if (ret > 0)
                {
                    flag = true;
                }
            }
            catch (Exception e)
            {
                err = e.Message;
            }
            return(flag);
        }
        public static int GetFailNumXcg()
        {
            int    num = 0;
            string sql = "select count(*) from zkhw_tj_xcg ";
            object obj = DbHelperAccess.GetSingle(sql);

            if (obj != null)
            {
                num = int.Parse(obj.ToString());
            }
            return(num);
        }
 public static DataSet getShenghuaXueChangGuiForYLH(string strSQL, string shpath)
 {
     try
     {
         DataSet ds     = new DataSet();
         string  strcon = "Provider=Microsoft.Jet.OLEDB.4.0; Data Source =" + shpath + "";
         ds = DbHelperAccess.Query(strSQL, strcon);
         return(ds);
     }
     catch (Exception r)
     {
         return(null);
     }
 }
        public static bool DeleteAccessXcg(string id)
        {
            bool flag = false;

            try
            {
                string sql = string.Format("Delete From zkhw_tj_xcg where id={0}", id);
                int    ret = DbHelperAccess.ExecuteSql(sql);
                if (ret > 0)
                {
                    flag = true;
                }
            }
            catch
            {
            }
            return(flag);
        }
        public static DataSet GetDataForAccess(string s, string top, string tdb, out string err)
        {
            err = "";
            DataSet ds = null;

            try
            {
                string sql = "select * from " + tdb + s;
                if (top != "")
                {
                    sql = "select top " + top + " * from " + tdb + s;
                }
                ds = DbHelperAccess.Query(sql);
            }
            catch (Exception e)
            {
                err = e.Message;
            }
            return(ds);
        }