Beispiel #1
0
        public static void Getgzinfo()
        {
            ClsDataSplitPar.ClsdirDirsn     = 0;
            ClsDataSplitPar.ClsFilesn       = 0;
            ClsDataSplitPar.ClsdirCol       = "";
            ClsDataSplitPar.ClsdirMl        = "";
            ClsDataSplitPar.ClsdirMlpage    = "";
            ClsDataSplitPar.ClsFileNmaecd   = 0;
            ClsDataSplitPar.ClsFileNameQian = "";
            ClsDataSplitPar.ClsFileNameHou  = "";
            ClsDataSplitPar.ClsFileNamecol  = "";
            ClsDataSplitPar.ClsFileDlname   = "";
            ClsDataSplitPar.ClsdirPageZero  = 0;
            ClsDataSplitPar.ClsFilezero     = false;
            ClsDataSplitPar.Clsdircolleg.Clear();
            DataTable dt = T_Sysset.GetDataSplit();

            if (dt == null || dt.Rows.Count <= 0)
            {
                return;
            }
            ClsDataSplitPar.ClsdirTable = dt.Rows[0][1].ToString();
            ClsDataSplitPar.ClsdirDirsn = Convert.ToInt32(dt.Rows[0][2].ToString());
            string str = dt.Rows[0][3].ToString();

            if (str.IndexOf('\\') >= 0)
            {
                string[] s = str.Split('\\');
                str = "";
                for (int i = 0; i < s.Length; i++)
                {
                    string[] z = s[i].Split(':');
                    if (str.Trim().Length <= 0)
                    {
                        str += z[0];
                    }
                    else
                    {
                        str += "," + z[0];
                    }
                    ClsDataSplitPar.Clsdircolleg.Add(z[1]);
                }
            }
            else if (str.IndexOf(':') >= 0)
            {
                string[] z = str.Split(':');
                str = z[0];
                ClsDataSplitPar.Clsdircolleg.Add(z[1]);
            }

            ClsDataSplitPar.ClsdirCol    = str;
            ClsDataSplitPar.ClsdirMl     = dt.Rows[0][4].ToString();
            ClsDataSplitPar.ClsFileTable = dt.Rows[0][5].ToString();
            ClsDataSplitPar.ClsFilesn    = Convert.ToInt32(dt.Rows[0][6].ToString());
            string file = dt.Rows[0][7].ToString();

            if (ClsDataSplitPar.ClsFilesn == 3)
            {
                ClsDataSplitPar.ClsFileNamecol = file;
            }
            else
            {
                if (file.IndexOf(';') >= 0)
                {
                    string[] f = file.Split(';');
                    string   s = f[0];
                    if (s.Trim().Length > 0)
                    {
                        ClsDataSplitPar.ClsFileNmaecd = Convert.ToInt32(f[0]);
                    }
                    else
                    {
                        ClsDataSplitPar.ClsFileNmaecd = 0;
                    }
                    ClsDataSplitPar.ClsFileNameQian = f[1];
                    ClsDataSplitPar.ClsFileNameHou  = f[2];
                }
                else
                {
                    ClsDataSplitPar.ClsFileNamecol = file;
                }
            }
            ClsDataSplitPar.ClsFilezero    = Convert.ToBoolean(dt.Rows[0][8].ToString());
            ClsDataSplitPar.ClsFileDlname  = dt.Rows[0][9].ToString();
            ClsDataSplitPar.ClsdirPageZero = Convert.ToInt32(dt.Rows[0][10].ToString());
            ClsDataSplitPar.ClsdirMlpage   = dt.Rows[0][11].ToString();
            GetExportTable();
        }