コード例 #1
0
        protected bool LineInit(int docknum)
        {
            bool flag = false;

            DAL.ZSql lineSql = new DAL.ZSql();
            if (docknum > 0)
            {
                lineSql.Open("Select RouteNum from T_ChargeSetting where ChargeNum=" + docknum + "Order by RouteNum");//升序
                if (lineSql.rowcount > 0)
                {
                    dockCount = lineSql.rowcount;   //确定停车位总数
                    dockLine  = new int[dockCount]; //确定停靠区每个车位的线路
                    for (int i = 0; i < lineSql.rowcount; i++)
                    {
                        if (!string.IsNullOrEmpty(lineSql.Rows[i]["RouteNum"].ToString()))
                        {
                            dockLine[i] = Convert.ToInt32(lineSql.Rows[i]["RouteNum"]);
                        }
                    }
                    flag = true;
                }
                lineSql.Close();
                lineSql.Dispose();
            }
            return(flag);
        }
コード例 #2
0
ファイル: AGVDock.cs プロジェクト: yy1244/AGV_Server
        protected bool DockInit(int docknum)
        {
            bool flag = false;

            DAL.ZSql dockSql = new DAL.ZSql();
            if (docknum > 0)
            {
                dockSql.Open("Select * from T_DockArea where DockNum=" + docknum.ToString());
                if (dockSql.rowcount > 0)
                {
                    dockNum            = docknum;
                    dockName           = dockSql.Rows[0]["DockName"].ToString();
                    dockStartStop.Num  = Convert.ToInt32(dockSql.Rows[0]["DockSSNum"]);
                    dockEndStop.Num    = Convert.ToInt32(dockSql.Rows[0]["DockESNum"]);
                    dockStartStop.Line = Convert.ToInt32(dockSql.Rows[0]["DockSSLine"]);
                    dockEndStop.Line   = Convert.ToInt32(dockSql.Rows[0]["DockESLine"]);
                    flag = true;
                }
                dockSql.Close();
                dockSql.Dispose();
            }
            return(flag);
        }
コード例 #3
0
ファイル: AGVDock.cs プロジェクト: qq5013/AGV_Client
 protected bool DockInit(int docknum)
 {
     bool flag = false;
     DAL.ZSql dockSql = new DAL.ZSql();
     if (docknum > 0)
     {
         dockSql.Open("Select * from T_DockArea where DockNum=" + docknum.ToString());
         if (dockSql.rowcount > 0)
         {
             dockNum = docknum;
             dockName = dockSql.Rows[0]["DockName"].ToString();
             dockStartStop.Num = Convert.ToInt32(dockSql.Rows[0]["DockSSNum"]);
             dockEndStop.Num = Convert.ToInt32(dockSql.Rows[0]["DockESNum"]);
             dockStartStop.Line = Convert.ToInt32(dockSql.Rows[0]["DockSSLine"]);
             dockEndStop.Line = Convert.ToInt32(dockSql.Rows[0]["DockESLine"]);
             flag = true;
         }
         dockSql.Close();
         dockSql.Dispose();
     }
     return flag;
 }
コード例 #4
0
ファイル: AGVDock.cs プロジェクト: qq5013/AGV_Client
 protected bool LineInit(int docknum)
 {
     bool flag = false;
     DAL.ZSql lineSql = new DAL.ZSql();
     if (docknum > 0)
     {
         lineSql.Open("Select RouteNum from T_DockSetting where DockNum=" + docknum + "Order by RouteNum");//升序
         if (lineSql.rowcount > 0)
         {
             dockCount = lineSql.rowcount;//确定停车位总数
             dockLine = new int[dockCount];//确定停靠区每个车位的线路
             outDockLine = new int[dockCount];
             for (int i = 0; i < lineSql.rowcount; i++)
             {
                 if (!string.IsNullOrEmpty(lineSql.Rows[i]["RouteNum"].ToString()))
                 {
                     dockLine[i] = Convert.ToInt32(lineSql.Rows[i]["RouteNum"]);
                 }
             }
             flag = true;
         }
         lineSql.Close();
         lineSql.Dispose();
     }
     return flag;
 }