using System;
using System.Collections;
using System.ComponentModel;
using System.Drawing;
using System.Data;
using System.Windows.Forms;

namespace Core.XgMes.Client.JGKC.SteelPlateManager
{
	/// <summary>
	/// 中板成品发运综合查询统计
	/// </summary>
	public class UCSendStat : System.Windows.Forms.UserControl
	{
		#region "Varible"
		private Infragistics.Win.UltraWinEditors.UltraCheckEditor chk_StatInceName;
		private Infragistics.Win.UltraWinEditors.UltraCheckEditor chk_StatStation;
		private Infragistics.Win.UltraWinEditors.UltraCheckEditor Chk_StatListCoding;
		private Infragistics.Win.UltraWinEditors.UltraCheckEditor Chk_StatSteel;
		private Infragistics.Win.UltraWinEditors.UltraCheckEditor Chk_StatVecihleNO;
		private Infragistics.Win.UltraWinEditors.UltraCheckEditor Chk_StatPactNO;
		private Infragistics.Win.UltraWinEditors.UltraCheckEditor Chk_StatPlanNO;
		private Infragistics.Win.UltraWinEditors.UltraCheckEditor Chk_StatRollNO;
        private Infragistics.Win.UltraWinEditors.UltraCheckEditor Chk_StatClassTeam;
		private Infragistics.Win.UltraWinEditors.UltraCheckEditor Chk_StatBilletID;
		private Infragistics.Win.UltraWinEditors.UltraCheckEditor Chk_StatRole;
		private Infragistics.Win.UltraWinEditors.UltraCheckEditor Chk_StatResult;
		private Infragistics.Win.UltraWinEditors.UltraCheckEditor Chk_StatSendDate;
		private Infragistics.Win.UltraWinEditors.UltraCheckEditor Chk_StatSpet;
		private Infragistics.Win.UltraWinEditors.UltraCheckEditor Chk_StatSendMan;
		private Infragistics.Win.UltraWinEditors.UltraCheckEditor Chk_StatBookInMan;
		private Infragistics.Win.UltraWinEditors.UltraCheckEditor Chk_StatBookInDate;
		private Infragistics.Win.UltraWinEditors.UltraCheckEditor chk_StatOrder;
		#endregion
		private Infragistics.Win.UltraWinEditors.UltraCheckEditor Chk_StatCondole;
		private Infragistics.Win.UltraWinEditors.UltraCheckEditor chk_ProcLine;
        private Infragistics.Win.UltraWinEditors.UltraCheckEditor chk_CutState;
        private Infragistics.Win.UltraWinEditors.UltraCheckEditor chk_SendNo;
        private Infragistics.Win.UltraWinEditors.UltraCheckEditor chk_Butress;
		/// <summary> 
		/// 必需的设计器变量。
		/// </summary>
		private System.ComponentModel.Container components = null;

		public UCSendStat()
		{
			// 该调用是 Windows.Forms 窗体设计器所必需的。
			InitializeComponent();

			// TODO: 在 InitializeComponent 调用后添加任何初始化

		}

		/// <summary> 
		/// 清理所有正在使用的资源。
		/// </summary>
		protected override void Dispose( bool disposing )
		{
			if( disposing )
			{
				if(components != null)
				{
					components.Dispose();
				}
			}
			base.Dispose( disposing );
		}

		#region 组件设计器生成的代码
		/// <summary> 
		/// 设计器支持所需的方法 - 不要使用代码编辑器 
		/// 修改此方法的内容。
		/// </summary>
		private void InitializeComponent()
		{
            Infragistics.Win.Appearance appearance1 = new Infragistics.Win.Appearance();
            Infragistics.Win.Appearance appearance2 = new Infragistics.Win.Appearance();
            Infragistics.Win.Appearance appearance3 = new Infragistics.Win.Appearance();
            Infragistics.Win.Appearance appearance4 = new Infragistics.Win.Appearance();
            Infragistics.Win.Appearance appearance5 = new Infragistics.Win.Appearance();
            Infragistics.Win.Appearance appearance6 = new Infragistics.Win.Appearance();
            Infragistics.Win.Appearance appearance7 = new Infragistics.Win.Appearance();
            Infragistics.Win.Appearance appearance8 = new Infragistics.Win.Appearance();
            Infragistics.Win.Appearance appearance9 = new Infragistics.Win.Appearance();
            Infragistics.Win.Appearance appearance10 = new Infragistics.Win.Appearance();
            Infragistics.Win.Appearance appearance11 = new Infragistics.Win.Appearance();
            Infragistics.Win.Appearance appearance12 = new Infragistics.Win.Appearance();
            Infragistics.Win.Appearance appearance13 = new Infragistics.Win.Appearance();
            Infragistics.Win.Appearance appearance14 = new Infragistics.Win.Appearance();
            Infragistics.Win.Appearance appearance15 = new Infragistics.Win.Appearance();
            Infragistics.Win.Appearance appearance16 = new Infragistics.Win.Appearance();
            Infragistics.Win.Appearance appearance17 = new Infragistics.Win.Appearance();
            Infragistics.Win.Appearance appearance18 = new Infragistics.Win.Appearance();
            Infragistics.Win.Appearance appearance19 = new Infragistics.Win.Appearance();
            Infragistics.Win.Appearance appearance20 = new Infragistics.Win.Appearance();
            Infragistics.Win.Appearance appearance21 = new Infragistics.Win.Appearance();
            Infragistics.Win.Appearance appearance22 = new Infragistics.Win.Appearance();
            Infragistics.Win.Appearance appearance23 = new Infragistics.Win.Appearance();
            this.chk_StatInceName = new Infragistics.Win.UltraWinEditors.UltraCheckEditor();
            this.chk_StatStation = new Infragistics.Win.UltraWinEditors.UltraCheckEditor();
            this.Chk_StatListCoding = new Infragistics.Win.UltraWinEditors.UltraCheckEditor();
            this.Chk_StatSteel = new Infragistics.Win.UltraWinEditors.UltraCheckEditor();
            this.Chk_StatVecihleNO = new Infragistics.Win.UltraWinEditors.UltraCheckEditor();
            this.Chk_StatPactNO = new Infragistics.Win.UltraWinEditors.UltraCheckEditor();
            this.Chk_StatPlanNO = new Infragistics.Win.UltraWinEditors.UltraCheckEditor();
            this.Chk_StatRollNO = new Infragistics.Win.UltraWinEditors.UltraCheckEditor();
            this.Chk_StatClassTeam = new Infragistics.Win.UltraWinEditors.UltraCheckEditor();
            this.Chk_StatBilletID = new Infragistics.Win.UltraWinEditors.UltraCheckEditor();
            this.Chk_StatRole = new Infragistics.Win.UltraWinEditors.UltraCheckEditor();
            this.Chk_StatCondole = new Infragistics.Win.UltraWinEditors.UltraCheckEditor();
            this.Chk_StatResult = new Infragistics.Win.UltraWinEditors.UltraCheckEditor();
            this.Chk_StatSendDate = new Infragistics.Win.UltraWinEditors.UltraCheckEditor();
            this.Chk_StatSpet = new Infragistics.Win.UltraWinEditors.UltraCheckEditor();
            this.Chk_StatSendMan = new Infragistics.Win.UltraWinEditors.UltraCheckEditor();
            this.Chk_StatBookInMan = new Infragistics.Win.UltraWinEditors.UltraCheckEditor();
            this.Chk_StatBookInDate = new Infragistics.Win.UltraWinEditors.UltraCheckEditor();
            this.chk_StatOrder = new Infragistics.Win.UltraWinEditors.UltraCheckEditor();
            this.chk_ProcLine = new Infragistics.Win.UltraWinEditors.UltraCheckEditor();
            this.chk_CutState = new Infragistics.Win.UltraWinEditors.UltraCheckEditor();
            this.chk_SendNo = new Infragistics.Win.UltraWinEditors.UltraCheckEditor();
            this.chk_Butress = new Infragistics.Win.UltraWinEditors.UltraCheckEditor();
            this.SuspendLayout();
            // 
            // chk_StatInceName
            // 
            appearance1.BackColor = System.Drawing.Color.LightCyan;
            this.chk_StatInceName.Appearance = appearance1;
            this.chk_StatInceName.FlatMode = true;
            this.chk_StatInceName.Location = new System.Drawing.Point(70, 6);
            this.chk_StatInceName.Name = "chk_StatInceName";
            this.chk_StatInceName.Size = new System.Drawing.Size(84, 14);
            this.chk_StatInceName.TabIndex = 0;
            this.chk_StatInceName.Text = "按收货单位";
            // 
            // chk_StatStation
            // 
            appearance2.BackColor = System.Drawing.Color.LightCyan;
            this.chk_StatStation.Appearance = appearance2;
            this.chk_StatStation.FlatMode = true;
            this.chk_StatStation.Location = new System.Drawing.Point(70, 38);
            this.chk_StatStation.Name = "chk_StatStation";
            this.chk_StatStation.Size = new System.Drawing.Size(59, 14);
            this.chk_StatStation.TabIndex = 1;
            this.chk_StatStation.Text = "按到站";
            // 
            // Chk_StatListCoding
            // 
            appearance3.BackColor = System.Drawing.Color.LightCyan;
            this.Chk_StatListCoding.Appearance = appearance3;
            this.Chk_StatListCoding.FlatMode = true;
            this.Chk_StatListCoding.Location = new System.Drawing.Point(70, 22);
            this.Chk_StatListCoding.Name = "Chk_StatListCoding";
            this.Chk_StatListCoding.Size = new System.Drawing.Size(72, 14);
            this.Chk_StatListCoding.TabIndex = 2;
            this.Chk_StatListCoding.Text = "按明细号";
            // 
            // Chk_StatSteel
            // 
            appearance4.BackColor = System.Drawing.Color.LightCyan;
            this.Chk_StatSteel.Appearance = appearance4;
            this.Chk_StatSteel.FlatMode = true;
            this.Chk_StatSteel.Location = new System.Drawing.Point(6, 54);
            this.Chk_StatSteel.Name = "Chk_StatSteel";
            this.Chk_StatSteel.Size = new System.Drawing.Size(59, 14);
            this.Chk_StatSteel.TabIndex = 3;
            this.Chk_StatSteel.Text = "按牌号";
            // 
            // Chk_StatVecihleNO
            // 
            appearance5.BackColor = System.Drawing.Color.LightCyan;
            this.Chk_StatVecihleNO.Appearance = appearance5;
            this.Chk_StatVecihleNO.FlatMode = true;
            this.Chk_StatVecihleNO.Location = new System.Drawing.Point(6, 6);
            this.Chk_StatVecihleNO.Name = "Chk_StatVecihleNO";
            this.Chk_StatVecihleNO.Size = new System.Drawing.Size(59, 14);
            this.Chk_StatVecihleNO.TabIndex = 4;
            this.Chk_StatVecihleNO.Text = "按车牌";
            // 
            // Chk_StatPactNO
            // 
            appearance6.BackColor = System.Drawing.Color.LightCyan;
            this.Chk_StatPactNO.Appearance = appearance6;
            this.Chk_StatPactNO.FlatMode = true;
            this.Chk_StatPactNO.Location = new System.Drawing.Point(6, 22);
            this.Chk_StatPactNO.Name = "Chk_StatPactNO";
            this.Chk_StatPactNO.Size = new System.Drawing.Size(59, 14);
            this.Chk_StatPactNO.TabIndex = 5;
            this.Chk_StatPactNO.Text = "按合同";
            // 
            // Chk_StatPlanNO
            // 
            appearance7.BackColor = System.Drawing.Color.LightCyan;
            this.Chk_StatPlanNO.Appearance = appearance7;
            this.Chk_StatPlanNO.FlatMode = true;
            this.Chk_StatPlanNO.Location = new System.Drawing.Point(70, 54);
            this.Chk_StatPlanNO.Name = "Chk_StatPlanNO";
            this.Chk_StatPlanNO.Size = new System.Drawing.Size(72, 14);
            this.Chk_StatPlanNO.TabIndex = 6;
            this.Chk_StatPlanNO.Text = "按计划号";
            // 
            // Chk_StatRollNO
            // 
            appearance8.BackColor = System.Drawing.Color.LightCyan;
            this.Chk_StatRollNO.Appearance = appearance8;
            this.Chk_StatRollNO.FlatMode = true;
            this.Chk_StatRollNO.Location = new System.Drawing.Point(70, 69);
            this.Chk_StatRollNO.Name = "Chk_StatRollNO";
            this.Chk_StatRollNO.Size = new System.Drawing.Size(72, 14);
            this.Chk_StatRollNO.TabIndex = 7;
            this.Chk_StatRollNO.Text = "按轧编号";
            // 
            // Chk_StatClassTeam
            // 
            appearance9.BackColor = System.Drawing.Color.LightCyan;
            this.Chk_StatClassTeam.Appearance = appearance9;
            this.Chk_StatClassTeam.FlatMode = true;
            this.Chk_StatClassTeam.Location = new System.Drawing.Point(6, 86);
            this.Chk_StatClassTeam.Name = "Chk_StatClassTeam";
            this.Chk_StatClassTeam.Size = new System.Drawing.Size(59, 14);
            this.Chk_StatClassTeam.TabIndex = 8;
            this.Chk_StatClassTeam.Text = "按班组";
            // 
            // Chk_StatBilletID
            // 
            appearance10.BackColor = System.Drawing.Color.LightCyan;
            this.Chk_StatBilletID.Appearance = appearance10;
            this.Chk_StatBilletID.FlatMode = true;
            this.Chk_StatBilletID.Location = new System.Drawing.Point(6, 102);
            this.Chk_StatBilletID.Name = "Chk_StatBilletID";
            this.Chk_StatBilletID.Size = new System.Drawing.Size(59, 14);
            this.Chk_StatBilletID.TabIndex = 10;
            this.Chk_StatBilletID.Text = "按序号";
            // 
            // Chk_StatRole
            // 
            appearance11.BackColor = System.Drawing.Color.LightCyan;
            this.Chk_StatRole.Appearance = appearance11;
            this.Chk_StatRole.FlatMode = true;
            this.Chk_StatRole.Location = new System.Drawing.Point(6, 118);
            this.Chk_StatRole.Name = "Chk_StatRole";
            this.Chk_StatRole.Size = new System.Drawing.Size(60, 14);
            this.Chk_StatRole.TabIndex = 11;
            this.Chk_StatRole.Text = "含定尺";
            // 
            // Chk_StatCondole
            // 
            appearance12.BackColor = System.Drawing.Color.LightCyan;
            this.Chk_StatCondole.Appearance = appearance12;
            this.Chk_StatCondole.FlatMode = true;
            this.Chk_StatCondole.Location = new System.Drawing.Point(158, 22);
            this.Chk_StatCondole.Name = "Chk_StatCondole";
            this.Chk_StatCondole.Size = new System.Drawing.Size(59, 14);
            this.Chk_StatCondole.TabIndex = 12;
            this.Chk_StatCondole.Text = "按吊号";
            // 
            // Chk_StatResult
            // 
            appearance13.BackColor = System.Drawing.Color.LightCyan;
            this.Chk_StatResult.Appearance = appearance13;
            this.Chk_StatResult.FlatMode = true;
            this.Chk_StatResult.Location = new System.Drawing.Point(70, 100);
            this.Chk_StatResult.Name = "Chk_StatResult";
            this.Chk_StatResult.Size = new System.Drawing.Size(84, 14);
            this.Chk_StatResult.TabIndex = 13;
            this.Chk_StatResult.Text = "含判定结果";
            // 
            // Chk_StatSendDate
            // 
            appearance14.BackColor = System.Drawing.Color.LightCyan;
            this.Chk_StatSendDate.Appearance = appearance14;
            this.Chk_StatSendDate.FlatMode = true;
            this.Chk_StatSendDate.Location = new System.Drawing.Point(70, 116);
            this.Chk_StatSendDate.Name = "Chk_StatSendDate";
            this.Chk_StatSendDate.Size = new System.Drawing.Size(84, 14);
            this.Chk_StatSendDate.TabIndex = 14;
            this.Chk_StatSendDate.Text = "按发运日期";
            // 
            // Chk_StatSpet
            // 
            appearance15.BackColor = System.Drawing.Color.LightCyan;
            this.Chk_StatSpet.Appearance = appearance15;
            this.Chk_StatSpet.FlatMode = true;
            this.Chk_StatSpet.Location = new System.Drawing.Point(6, 70);
            this.Chk_StatSpet.Name = "Chk_StatSpet";
            this.Chk_StatSpet.Size = new System.Drawing.Size(59, 14);
            this.Chk_StatSpet.TabIndex = 15;
            this.Chk_StatSpet.Text = "按规格";
            // 
            // Chk_StatSendMan
            // 
            appearance16.BackColor = System.Drawing.Color.LightCyan;
            this.Chk_StatSendMan.Appearance = appearance16;
            this.Chk_StatSendMan.FlatMode = true;
            this.Chk_StatSendMan.Location = new System.Drawing.Point(6, 134);
            this.Chk_StatSendMan.Name = "Chk_StatSendMan";
            this.Chk_StatSendMan.Size = new System.Drawing.Size(59, 14);
            this.Chk_StatSendMan.TabIndex = 16;
            this.Chk_StatSendMan.Text = "发运人";
            // 
            // Chk_StatBookInMan
            // 
            appearance17.BackColor = System.Drawing.Color.LightCyan;
            this.Chk_StatBookInMan.Appearance = appearance17;
            this.Chk_StatBookInMan.FlatMode = true;
            this.Chk_StatBookInMan.Location = new System.Drawing.Point(6, 150);
            this.Chk_StatBookInMan.Name = "Chk_StatBookInMan";
            this.Chk_StatBookInMan.Size = new System.Drawing.Size(59, 14);
            this.Chk_StatBookInMan.TabIndex = 17;
            this.Chk_StatBookInMan.Text = "登记人";
            // 
            // Chk_StatBookInDate
            // 
            appearance18.BackColor = System.Drawing.Color.LightCyan;
            this.Chk_StatBookInDate.Appearance = appearance18;
            this.Chk_StatBookInDate.FlatMode = true;
            this.Chk_StatBookInDate.Location = new System.Drawing.Point(70, 132);
            this.Chk_StatBookInDate.Name = "Chk_StatBookInDate";
            this.Chk_StatBookInDate.Size = new System.Drawing.Size(84, 14);
            this.Chk_StatBookInDate.TabIndex = 18;
            this.Chk_StatBookInDate.Text = "按登记时间";
            // 
            // chk_StatOrder
            // 
            appearance19.BackColor = System.Drawing.Color.LightCyan;
            this.chk_StatOrder.Appearance = appearance19;
            this.chk_StatOrder.FlatMode = true;
            this.chk_StatOrder.Location = new System.Drawing.Point(6, 38);
            this.chk_StatOrder.Name = "chk_StatOrder";
            this.chk_StatOrder.Size = new System.Drawing.Size(59, 14);
            this.chk_StatOrder.TabIndex = 19;
            this.chk_StatOrder.Text = "按订单";
            // 
            // chk_ProcLine
            // 
            appearance20.BackColor = System.Drawing.Color.LightCyan;
            this.chk_ProcLine.Appearance = appearance20;
            this.chk_ProcLine.FlatMode = true;
            this.chk_ProcLine.Location = new System.Drawing.Point(158, 6);
            this.chk_ProcLine.Name = "chk_ProcLine";
            this.chk_ProcLine.Size = new System.Drawing.Size(48, 14);
            this.chk_ProcLine.TabIndex = 20;
            this.chk_ProcLine.Text = "产线";
            // 
            // chk_CutState
            // 
            appearance21.BackColor = System.Drawing.Color.LightCyan;
            this.chk_CutState.Appearance = appearance21;
            this.chk_CutState.FlatMode = true;
            this.chk_CutState.Location = new System.Drawing.Point(70, 84);
            this.chk_CutState.Name = "chk_CutState";
            this.chk_CutState.Size = new System.Drawing.Size(84, 14);
            this.chk_CutState.TabIndex = 21;
            this.chk_CutState.Text = "按切边状态";
            // 
            // chk_SendNo
            // 
            appearance22.BackColor = System.Drawing.Color.LightCyan;
            this.chk_SendNo.Appearance = appearance22;
            this.chk_SendNo.FlatMode = true;
            this.chk_SendNo.Location = new System.Drawing.Point(158, 38);
            this.chk_SendNo.Name = "chk_SendNo";
            this.chk_SendNo.Size = new System.Drawing.Size(59, 14);
            this.chk_SendNo.TabIndex = 24;
            this.chk_SendNo.Text = "发运号";
            // 
            // chk_Butress
            // 
            appearance23.BackColor = System.Drawing.Color.LightCyan;
            this.chk_Butress.Appearance = appearance23;
            this.chk_Butress.FlatMode = true;
            this.chk_Butress.Location = new System.Drawing.Point(158, 53);
            this.chk_Butress.Name = "chk_Butress";
            this.chk_Butress.Size = new System.Drawing.Size(74, 14);
            this.chk_Butress.TabIndex = 26;
            this.chk_Butress.Text = "垛位";
            // 
            // UCSendStat
            // 
            this.Controls.Add(this.chk_Butress);
            this.Controls.Add(this.chk_SendNo);
            this.Controls.Add(this.chk_CutState);
            this.Controls.Add(this.chk_ProcLine);
            this.Controls.Add(this.chk_StatOrder);
            this.Controls.Add(this.Chk_StatBookInDate);
            this.Controls.Add(this.Chk_StatBookInMan);
            this.Controls.Add(this.Chk_StatSendMan);
            this.Controls.Add(this.Chk_StatSpet);
            this.Controls.Add(this.Chk_StatSendDate);
            this.Controls.Add(this.Chk_StatResult);
            this.Controls.Add(this.Chk_StatCondole);
            this.Controls.Add(this.Chk_StatRole);
            this.Controls.Add(this.Chk_StatBilletID);
            this.Controls.Add(this.Chk_StatClassTeam);
            this.Controls.Add(this.Chk_StatRollNO);
            this.Controls.Add(this.Chk_StatPlanNO);
            this.Controls.Add(this.Chk_StatPactNO);
            this.Controls.Add(this.Chk_StatVecihleNO);
            this.Controls.Add(this.Chk_StatSteel);
            this.Controls.Add(this.Chk_StatListCoding);
            this.Controls.Add(this.chk_StatStation);
            this.Controls.Add(this.chk_StatInceName);
            this.Name = "UCSendStat";
            this.Size = new System.Drawing.Size(233, 173);
            this.ResumeLayout(false);

		}
		#endregion

		#region "Property
		private string _SelectStr = "SELECT ";//A.STEELTYPE
        private string _FromStr = " FROM KCJ_TURNOFFSENDLIST_ZW A,SEL_PACTDETAIL B,SEL_INCEPTCORPINFO C,SEL_STATIONINFO D,KCJ_PLAN E,SEL_PACTINFO F  "
                                 + " WHERE A.ISVALID<>'0' AND A.SENDTYPE='0' AND A.PLANVEHICLEID=E.ASKPLAN_ID(+) AND E.INCEPTCORPCODE=C.INCEPTCORPCODE(+) AND A.DUMMYSENDFLAG<>'1' "
                                 + " AND B.STATIONCODE=D.STATIONCODE(+) AND A.ORDERFORMNUMBER=B.ORDERNO(+) AND A.CLEARFLAG <> '1' AND E.PACTNO=F.PACTNO(+)  ";


        private string _FromStr1 = " FROM KCJ_TURNOFFSENDLIST_ZW A,SEL_PACTDETAIL B,SEL_INCEPTCORPINFO C,SEL_STATIONINFO D,KCJ_PLAN E,SEL_PACTINFO F  "
                                 + " WHERE A.ISVALID<>'0' AND A.SENDTYPE='0' AND A.PLANVEHICLEID=E.ASKPLAN_ID(+) AND E.INCEPTCORPCODE=C.INCEPTCORPCODE(+) AND A.DUMMYSENDFLAG<>'1' "
                                 + " AND B.STATIONCODE=D.STATIONCODE(+) AND A.ORDERFORMNUMBER=B.ORDERNO(+) AND A.CLEARFLAG <> '1' AND E.PACTNO=F.PACTNO AND F.ISOUTPACT='1' ";
        private string _GroupbyStr = " GROUP BY ";

		public System.Collections.ArrayList SendSelectStr
		{
			get
			{
				System.Collections.ArrayList rtnList = new ArrayList();
				string rtnStr = _SelectStr;

				
                if (this.chk_SendNo.Checked)
                {
                    if (rtnStr.Length > 7)
                    {
                        rtnStr = rtnStr + ",A.PLANVEHICLEID ";
                    }
                    else
                    {
                        rtnStr = rtnStr + "A.PLANVEHICLEID ";
                    }
                }
              
                if (this.chk_Butress.Checked)
                {
                    if (rtnStr.Length > 7)
                    {
                        rtnStr = rtnStr + ",A.BUTTRESS";
                    }
                    else
                    {
                        rtnStr = rtnStr + "A.BUTTRESS";
                    }
                }
				if(this.chk_CutState.Checked)
				{
					if(rtnStr.Length>7)
					{
						rtnStr = rtnStr + ",(SELECT  NAME_  FROM  SCM_BASE_INFO  WHERE  ID_ = A.CLIPTYPEPROCESS) CLIPTYPEPROCESS";
					}
					else
					{
						rtnStr = rtnStr + "(SELECT  NAME_  FROM  SCM_BASE_INFO  WHERE  ID_ = A.CLIPTYPEPROCESS) CLIPTYPEPROCESS";
					}
				}

				if(this.chk_ProcLine.Checked)
				{
					if(rtnStr.Length>7)
					{
						rtnStr = rtnStr + ",(SELECT  NAME_  FROM  SCM_BASE_INFO  WHERE  ID_ = B.PRODLINECODE) PRODLINECODE";
					}
					else
					{
						rtnStr = rtnStr + "(SELECT  NAME_  FROM  SCM_BASE_INFO  WHERE  ID_ = B.PRODLINECODE) PRODLINECODE";
					}
				}

				if(this.chk_StatInceName.Checked)
				{
					if(rtnStr.Length>7)
					{
						rtnStr = rtnStr + ",C.INCEPTCORPNAME";
					}
					else
					{
						rtnStr = rtnStr + "C.INCEPTCORPNAME";
					}
				}
				if(this.Chk_StatListCoding.Checked)
				{
					if(rtnStr.Length>7)
					{
						rtnStr = rtnStr + ",A.LISTNUMBER";
					}
					else
					{
						rtnStr = rtnStr + "A.LISTNUMBER";
					}
				}
				if(this.Chk_StatVecihleNO.Checked)
				{
					if(rtnStr.Length>7)
					{
						rtnStr = rtnStr + ",A.TRAINWAGON";
					}
					else
					{
						rtnStr = rtnStr + "A.TRAINWAGON";
					}
				}
             
              
				if(this.chk_StatStation.Checked)
				{
					if(rtnStr.Length>7)
					{
						rtnStr = rtnStr + ",D.STATIONNAME";
					}
					else
					{
						rtnStr = rtnStr + "D.STATIONNAME";
					}
				}
				if(this.Chk_StatPactNO.Checked)
				{
					if(rtnStr.Length>7)
					{
						rtnStr = rtnStr + ",B.PACTNO";
					}
					else
					{
						rtnStr = rtnStr + "B.PACTNO";
					}
				}
				if(this.chk_StatOrder.Checked)
				{
					if(rtnStr.Length>7)
					{
						rtnStr = rtnStr + ",A.ORDERFORMNUMBER";
					}
					else
					{
						rtnStr = rtnStr + "A.ORDERFORMNUMBER";
					}
				}
				if(this.Chk_StatPlanNO.Checked)
				{
					if(rtnStr.Length>7)
					{
						rtnStr = rtnStr + ",A.PLANNO";
					}
					else
					{
						rtnStr = rtnStr + "A.PLANNO";
					}
				}
				if(this.Chk_StatSteel.Checked)
				{
					if(rtnStr.Length>7)
					{
						rtnStr = rtnStr + ",A.STEELTYPE";
					}
					else
					{
						rtnStr = rtnStr + "A.STEELTYPE";
					}
				}
				if(this.Chk_StatRollNO.Checked)
				{
					if(rtnStr.Length>7)
					{
						rtnStr = rtnStr + ",A.ROLLNO";
					}
					else
					{
						rtnStr = rtnStr + "A.ROLLNO";
					}
				}
				if(this.Chk_StatClassTeam.Checked)
				{
					if(rtnStr.Length>7)
					{
						rtnStr = rtnStr + ",(SELECT NAME_ FROM SCM_BASE_INFO WHERE ID_=A.CLASSTEAM) CLASSTEAM";
					}
					else
					{
						rtnStr = rtnStr + "(SELECT NAME_ FROM SCM_BASE_INFO WHERE ID_=A.CLASSTEAM) CLASSTEAM";
					}
				}
			
				if(this.Chk_StatRole.Checked)
				{
					if(rtnStr.Length>7)
					{
						rtnStr = rtnStr+ ",(SELECT NAME_ FROM SCM_BASE_INFO WHERE ID_=A.ROLE) ROLE";
					}
					else
					{
						rtnStr = rtnStr+ "(SELECT NAME_ FROM SCM_BASE_INFO WHERE ID_=A.ROLE) ROLE";
					}
				}
				if(this.Chk_StatCondole.Checked)
				{
					if(rtnStr.Length>7)
					{
						rtnStr = rtnStr + ",A.CONDOLENUMBER";
					}
					else
					{
						rtnStr = rtnStr + "A.CONDOLENUMBER";
					}
				}
				if(this.Chk_StatResult.Checked)
				{
					if(rtnStr.Length>7)
					{
						rtnStr = rtnStr + ",(SELECT NAME_ FROM SCM_BASE_INFO WHERE ID_=A.DETERMINANTRESULT) DETERMINANTRESULT";
					}
					else
					{
						rtnStr = rtnStr + "(SELECT NAME_ FROM SCM_BASE_INFO WHERE ID_=A.DETERMINANTRESULT) DETERMINANTRESULT";
					}
				}
				if(this.Chk_StatSendDate.Checked)
				{
					if(rtnStr.Length>7)
					{
						rtnStr = rtnStr + ",TO_CHAR(A.PICKSTORAGETIME,'YY-MM-DD') PICKSTORAGETIME";
					}
					else
					{
						rtnStr = rtnStr + "TO_CHAR(A.PICKSTORAGETIME,'YY-MM-DD') PICKSTORAGETIME";
					}
				}
				if(this.Chk_StatBookInDate.Checked)
				{
					if(rtnStr.Length>7)
					{
						rtnStr = rtnStr + ",TO_CHAR(A.CREATTIME,'YY-MM-DD HH24:MI') CREATTIME";
					}
					else
					{
						rtnStr = rtnStr + "TO_CHAR(A.CREATTIME,'YY-MM-DD HH24:MI') CREATTIME";
					}
				}
				if(this.Chk_StatBookInMan.Checked)
				{
					if(rtnStr.Length>7)
					{
						rtnStr = rtnStr + ",A.CREATOR";
					}
					else
					{
						rtnStr = rtnStr + "A.CREATOR";
					}
				}
				if(this.Chk_StatSendMan.Checked)
				{
					if(rtnStr.Length>7)
					{
						rtnStr = rtnStr + ",A.PICKSTORAGEMAN";
					}
					else
					{
						rtnStr = rtnStr + "A.PICKSTORAGEMAN";
					}
				}
               
				if(this.Chk_StatBilletID.Checked)
				{
					if(rtnStr.Length>7)
					{
						rtnStr = rtnStr + ",A.SERIALNUMBER,1 QUANTITY,A.WEIGHT,A.ADDWEIGHT ";
					}
					else
					{
						rtnStr = rtnStr + "C.INCEPTCORPNAME,A.LISTNUMBER,A.STEELTYPE,TO_CHAR(A.PICKSTORAGETIME,'YY-MM-DD') PICKSTORAGETIME,A.SERIALNUMBER,1 QUANTITY,A.WEIGHT,A.ADDWEIGHT ";
					}
					rtnStr = rtnStr + ",TO_CHAR(A.PLY)||'×'||TO_CHAR(A.WIDTH)||'×'||TO_CHAR(A.LENGTH) SPET";
					rtnStr = rtnStr + _FromStr;
					rtnList.Add(rtnStr);
					return rtnList;
				}
				else
				{
					if(rtnStr.Length>7)
					{
						rtnStr = rtnStr + ",COUNT(A.SERIALNUMBER) QUANTITY,SUM(A.WEIGHT) WEIGHT,SUM(A.ADDWEIGHT) ADDWEIGHT "; 
					}
					else
					{
						rtnStr = rtnStr + "C.INCEPTCORPNAME,A.LISTNUMBER,A.STEELTYPE,TO_CHAR(A.PICKSTORAGETIME,'YY-MM-DD') PICKSTORAGETIME,COUNT(A.SERIALNUMBER) QUANTITY,SUM(A.WEIGHT) WEIGHT,SUM(A.ADDWEIGHT) ADDWEIGHT "; 
					}
				}
                if (this.Chk_StatRole.Checked)
                {
                    string tmpstr = "";
                    tmpstr = rtnStr + ",TO_CHAR(A.PLY)||'×'||TO_CHAR(A.LENGTH) SPET ";       //定长
                    tmpstr = tmpstr + _FromStr + " AND A.ROLE='102201' ";
                    rtnList.Add(tmpstr);
                    tmpstr = rtnStr + ",TO_CHAR(A.PLY)||'×'||TO_CHAR(A.WIDTH) SPET ";      //定宽
                    tmpstr = tmpstr + _FromStr + " AND (A.ROLE='102202' OR A.ROLE='102206') ";
                    rtnList.Add(tmpstr);
                    tmpstr = rtnStr + ",TO_CHAR(A.PLY)||'×'||TO_CHAR(A.WIDTH)||'×'||TO_CHAR(A.LENGTH) SPET ";      //双定
                    tmpstr = tmpstr + _FromStr + " AND (A.ROLE='102203' OR A.ROLE IS NULL) ";
                    rtnList.Add(tmpstr);
                    tmpstr = rtnStr + ",TO_CHAR(A.PLY) SPET ";      //非定
                    tmpstr = tmpstr + _FromStr + " AND (A.ROLE='102204' OR A.ROLE='102205') ";
                    rtnList.Add(tmpstr);
                    return rtnList;
                }
                else
                {
                    if (this.Chk_StatSpet.Checked)
                    {
                        rtnStr = rtnStr + ",TO_CHAR(A.PLY) SPET ";
                    }
                    rtnStr = rtnStr + _FromStr;
                    rtnList.Add(rtnStr);
                    return rtnList;
                }
			}
		}



        public System.Collections.ArrayList SendSelectStr1
        {
            get
            {
                System.Collections.ArrayList rtnList = new ArrayList();
                string rtnStr = _SelectStr;

                
               
              
                if (this.chk_SendNo.Checked)
                {
                    if (rtnStr.Length > 7)
                    {
                        rtnStr = rtnStr + ",A.PLANVEHICLEID";
                    }
                    else
                    {
                        rtnStr = rtnStr + "A.PLANVEHICLEID";
                    }
                }

             
                
                if (this.chk_Butress.Checked)
                {
                    if (rtnStr.Length > 7)
                    {
                        rtnStr = rtnStr + ",A.BUTTRESS";
                    }
                    else
                    {
                        rtnStr = rtnStr + "A.BUTTRESS";
                    }
                }
                if (this.chk_CutState.Checked)
                {
                    if (rtnStr.Length > 7)
                    {
                        rtnStr = rtnStr + ",(SELECT  NAME_  FROM  SCM_BASE_INFO  WHERE  ID_ = A.CLIPTYPEPROCESS) CLIPTYPEPROCESS";
                    }
                    else
                    {
                        rtnStr = rtnStr + "(SELECT  NAME_  FROM  SCM_BASE_INFO  WHERE  ID_ = A.CLIPTYPEPROCESS) CLIPTYPEPROCESS";
                    }
                }

                if (this.chk_ProcLine.Checked)
                {
                    if (rtnStr.Length > 7)
                    {
                        rtnStr = rtnStr + ",(SELECT  NAME_  FROM  SCM_BASE_INFO  WHERE  ID_ = B.PRODLINECODE) PRODLINECODE";
                    }
                    else
                    {
                        rtnStr = rtnStr + "(SELECT  NAME_  FROM  SCM_BASE_INFO  WHERE  ID_ = B.PRODLINECODE) PRODLINECODE";
                    }
                }

                if (this.chk_StatInceName.Checked)
                {
                    if (rtnStr.Length > 7)
                    {
                        rtnStr = rtnStr + ",C.INCEPTCORPNAME";
                    }
                    else
                    {
                        rtnStr = rtnStr + "C.INCEPTCORPNAME";
                    }
                }
                if (this.Chk_StatListCoding.Checked)
                {
                    if (rtnStr.Length > 7)
                    {
                        rtnStr = rtnStr + ",A.LISTNUMBER";
                    }
                    else
                    {
                        rtnStr = rtnStr + "A.LISTNUMBER";
                    }
                }
                if (this.Chk_StatVecihleNO.Checked)
                {
                    if (rtnStr.Length > 7)
                    {
                        rtnStr = rtnStr + ",A.TRAINWAGON";
                    }
                    else
                    {
                        rtnStr = rtnStr + "A.TRAINWAGON";
                    }
                }
               
               
                if (this.chk_StatStation.Checked)
                {
                    if (rtnStr.Length > 7)
                    {
                        rtnStr = rtnStr + ",D.STATIONNAME";
                    }
                    else
                    {
                        rtnStr = rtnStr + "D.STATIONNAME";
                    }
                }
                if (this.Chk_StatPactNO.Checked)
                {
                    if (rtnStr.Length > 7)
                    {
                        rtnStr = rtnStr + ",B.PACTNO,";
                    }
                    else
                    {
                        rtnStr = rtnStr + "B.PACTNO,";
                    }
                }
                if (this.chk_StatOrder.Checked)
                {
                    if (rtnStr.Length > 7)
                    {
                        rtnStr = rtnStr + ",A.ORDERFORMNUMBER";
                    }
                    else
                    {
                        rtnStr = rtnStr + "A.ORDERFORMNUMBER";
                    }
                }
                if (this.Chk_StatPlanNO.Checked)
                {
                    if (rtnStr.Length > 7)
                    {
                        rtnStr = rtnStr + ",A.PLANNO";
                    }
                    else
                    {
                        rtnStr = rtnStr + "A.PLANNO";
                    }
                }
                if (this.Chk_StatSteel.Checked)
                {
                    if (rtnStr.Length > 7)
                    {
                        rtnStr = rtnStr + ",A.STEELTYPE";
                    }
                    else
                    {
                        rtnStr = rtnStr + "A.STEELTYPE";
                    }
                }
                if (this.Chk_StatRollNO.Checked)
                {
                    if (rtnStr.Length > 7)
                    {
                        rtnStr = rtnStr + ",A.ROLLNO";
                    }
                    else
                    {
                        rtnStr = rtnStr + "A.ROLLNO";
                    }
                }
                if (this.Chk_StatClassTeam.Checked)
                {
                    if (rtnStr.Length > 7)
                    {
                        rtnStr = rtnStr + ",(SELECT NAME_ FROM SCM_BASE_INFO WHERE ID_=A.CLASSTEAM) CLASSTEAM";
                    }
                    else
                    {
                        rtnStr = rtnStr + "(SELECT NAME_ FROM SCM_BASE_INFO WHERE ID_=A.CLASSTEAM) CLASSTEAM";
                    }
                }
              
                if (this.Chk_StatRole.Checked)
                {
                    if (rtnStr.Length > 7)
                    {
                        rtnStr = rtnStr + ",(SELECT NAME_ FROM SCM_BASE_INFO WHERE ID_=A.ROLE) ROLE";
                    }
                    else
                    {
                        rtnStr = rtnStr + "(SELECT NAME_ FROM SCM_BASE_INFO WHERE ID_=A.ROLE) ROLE";
                    }
                }
                if (this.Chk_StatCondole.Checked)
                {
                    if (rtnStr.Length > 7)
                    {
                        rtnStr = rtnStr + ",A.CONDOLENUMBER";
                    }
                    else
                    {
                        rtnStr = rtnStr + "A.CONDOLENUMBER";
                    }
                }
                if (this.Chk_StatResult.Checked)
                {
                    if (rtnStr.Length > 7)
                    {
                        rtnStr = rtnStr + ",(SELECT NAME_ FROM SCM_BASE_INFO WHERE ID_=A.DETERMINANTRESULT) DETERMINANTRESULT";
                    }
                    else
                    {
                        rtnStr = rtnStr + "(SELECT NAME_ FROM SCM_BASE_INFO WHERE ID_=A.DETERMINANTRESULT) DETERMINANTRESULT";
                    }
                }
                if (this.Chk_StatSendDate.Checked)
                {
                    if (rtnStr.Length > 7)
                    {
                        rtnStr = rtnStr + ",TO_CHAR(A.PICKSTORAGETIME,'YY-MM-DD') PICKSTORAGETIME";
                    }
                    else
                    {
                        rtnStr = rtnStr + "TO_CHAR(A.PICKSTORAGETIME,'YY-MM-DD') PICKSTORAGETIME";
                    }
                }
                if (this.Chk_StatBookInDate.Checked)
                {
                    if (rtnStr.Length > 7)
                    {
                        rtnStr = rtnStr + ",TO_CHAR(A.CREATTIME,'YY-MM-DD HH24:MI') CREATTIME";
                    }
                    else
                    {
                        rtnStr = rtnStr + "TO_CHAR(A.CREATTIME,'YY-MM-DD HH24:MI') CREATTIME";
                    }
                }
                if (this.Chk_StatBookInMan.Checked)
                {
                    if (rtnStr.Length > 7)
                    {
                        rtnStr = rtnStr + ",A.CREATOR";
                    }
                    else
                    {
                        rtnStr = rtnStr + "A.CREATOR";
                    }
                }
                if (this.Chk_StatSendMan.Checked)
                {
                    if (rtnStr.Length > 7)
                    {
                        rtnStr = rtnStr + ",A.PICKSTORAGEMAN";
                    }
                    else
                    {
                        rtnStr = rtnStr + "A.PICKSTORAGEMAN";
                    }
                }
               
               
                if (this.Chk_StatBilletID.Checked)
                {
                    if (rtnStr.Length > 7)
                    {
                        rtnStr = rtnStr + ",A.SERIALNUMBER,1 QUANTITY,A.WEIGHT,A.ADDWEIGHT ";
                    }
                    else
                    {
                        rtnStr = rtnStr + "C.INCEPTCORPNAME,A.LISTNUMBER,A.STEELTYPE,TO_CHAR(A.PICKSTORAGETIME,'YY-MM-DD') PICKSTORAGETIME,A.SERIALNUMBER,1 QUANTITY,A.WEIGHT,A.ADDWEIGHT  ";
                    }
                    rtnStr = rtnStr + ",TO_CHAR(A.PLY)||'×'||TO_CHAR(A.WIDTH)||'×'||TO_CHAR(A.LENGTH) SPET";
                    rtnStr = rtnStr + _FromStr1;
                    rtnList.Add(rtnStr);
                    return rtnList;
                }
                else
                {
                    if (rtnStr.Length > 7)
                    {
                        rtnStr = rtnStr + ",COUNT(A.SERIALNUMBER) QUANTITY,SUM(A.WEIGHT) WEIGHT,SUM(A.ADDWEIGHT) ADDWEIGHT  ";
                    }
                    else
                    {
                        rtnStr = rtnStr + "C.INCEPTCORPNAME,A.LISTNUMBER,A.STEELTYPE,TO_CHAR(A.PICKSTORAGETIME,'YY-MM-DD') PICKSTORAGETIME,COUNT(A.SERIALNUMBER) QUANTITY,SUM(A.WEIGHT) WEIGHT,SUM(A.ADDWEIGHT) ADDWEIGHT,SUM(A.ACREAGE) ACREAGE ";
                    }
                }
                if (this.Chk_StatRole.Checked)
                {
                    string tmpstr = "";
                    tmpstr = rtnStr + ",TO_CHAR(A.PLY)||'×'||TO_CHAR(A.LENGTH) SPET ";       //定长
                    tmpstr = tmpstr + _FromStr1 + " AND A.ROLE='102201' ";
                    rtnList.Add(tmpstr);
                    tmpstr = rtnStr + ",TO_CHAR(A.PLY)||'×'||TO_CHAR(A.WIDTH) SPET ";      //定宽
                    tmpstr = tmpstr + _FromStr1 + " AND (A.ROLE='102202' OR A.ROLE='102206') ";
                    rtnList.Add(tmpstr);
                    tmpstr = rtnStr + ",TO_CHAR(A.PLY)||'×'||TO_CHAR(A.WIDTH)||'×'||TO_CHAR(A.LENGTH) SPET ";      //双定
                    tmpstr = tmpstr + _FromStr1 + " AND (A.ROLE='102203' OR A.ROLE IS NULL) ";
                    rtnList.Add(tmpstr);
                    tmpstr = rtnStr + ",TO_CHAR(A.PLY) SPET ";      //非定
                    tmpstr = tmpstr + _FromStr1 + " AND (A.ROLE='102204' OR A.ROLE='102205') ";
                    rtnList.Add(tmpstr);
                    return rtnList;
                }
                else
                {
                    if (this.Chk_StatSpet.Checked)
                    {
                        rtnStr = rtnStr + ",TO_CHAR(A.PLY) SPET ";
                    }
                    rtnStr = rtnStr + _FromStr1;
                    rtnList.Add(rtnStr);
                    return rtnList;
                }
            }
        }
		public System.Collections.ArrayList SendGroupbyStr
		{
			get
			{
				System.Collections.ArrayList rtnList = new ArrayList();
				string rtnStr = _GroupbyStr;

				
              
                if (this.chk_Butress.Checked)
                {
                    if (rtnStr.Length > 10)
                    {
                        rtnStr = rtnStr + ",A.BUTTRESS";
                    }
                    else
                    {
                        rtnStr = rtnStr + "A.BUTTRESS";
                    }
                }
                	if(this.chk_SendNo.Checked)
				{
					if(rtnStr.Length>10)
					{
                        rtnStr = rtnStr + ",A.PLANVEHICLEID";
					}
					else
					{
                        rtnStr = rtnStr + "A.PLANVEHICLEID";
					}
				}

				if(this.chk_CutState.Checked)
				{
					if(rtnStr.Length>10)
					{
						rtnStr = rtnStr + ",A.CLIPTYPEPROCESS";
					}
					else
					{
						rtnStr = rtnStr + "A.CLIPTYPEPROCESS";
					}
				}

				if(this.chk_ProcLine.Checked)
				{
					if(rtnStr.Length>10)
					{
						rtnStr = rtnStr + ",B.PRODLINECODE";
					}
					else
					{
						rtnStr = rtnStr + "B.PRODLINECODE";
					}
				}

				if(this.chk_StatInceName.Checked)
				{
					if(rtnStr.Length>10)
					{
						rtnStr = rtnStr + ",C.INCEPTCORPNAME";
					}
					else
					{
						rtnStr = rtnStr + "C.INCEPTCORPNAME";
					}
				}
				if(this.Chk_StatListCoding.Checked)
				{
					if(rtnStr.Length>10)
					{
						rtnStr = rtnStr + ",A.LISTNUMBER";
					}
					else
					{
						rtnStr = rtnStr + "A.LISTNUMBER";
					}
				}
				if(this.Chk_StatVecihleNO.Checked)
				{
					if(rtnStr.Length>10)
					{
						rtnStr = rtnStr + ",A.TRAINWAGON";
					}
					else
					{
						rtnStr = rtnStr + "A.TRAINWAGON";
					}
				}
               
              
				if(this.chk_StatStation.Checked)
				{
					if(rtnStr.Length>10)
					{
						rtnStr = rtnStr + ",D.STATIONNAME";
					}
					else
					{
						rtnStr = rtnStr + "D.STATIONNAME";
					}
				}
				if(this.Chk_StatPactNO.Checked)
				{
					if(rtnStr.Length>10)
					{
						rtnStr = rtnStr + ",B.PACTNO,B.SIGNCOLOR";
					}
					else
					{
						rtnStr = rtnStr + "B.PACTNO,B.SIGNCOLOR";
					}
				}
				if(this.chk_StatOrder.Checked)
				{
					if(rtnStr.Length>10)
					{
						rtnStr = rtnStr + ",A.ORDERFORMNUMBER";
					}
					else
					{
						rtnStr = rtnStr + "A.ORDERFORMNUMBER";
					}
				}
              
				if(this.Chk_StatPlanNO.Checked)
				{
					if(rtnStr.Length>10)
					{
						rtnStr = rtnStr + ",A.PLANNO";
					}
					else
					{
						rtnStr = rtnStr + "A.PLANNO";
					}
				}
				if(this.Chk_StatSteel.Checked)
				{
					if(rtnStr.Length>10)
					{
						rtnStr = rtnStr + ",A.STEELTYPE";
					}
					else
					{
						rtnStr = rtnStr + "A.STEELTYPE";
					}
				}
				if(this.Chk_StatRollNO.Checked)
				{
					if(rtnStr.Length>10)
					{
						rtnStr = rtnStr + ",A.ROLLNO";
					}
					else
					{
						rtnStr = rtnStr + "A.ROLLNO";
					}
				}
				if(this.Chk_StatClassTeam.Checked)
				{
					if(rtnStr.Length>10)
					{
						rtnStr = rtnStr + ",A.CLASSTEAM";
					}
					else
					{
						rtnStr = rtnStr + "A.CLASSTEAM";
					}
				}
				
				if(this.Chk_StatRole.Checked)
				{
					if(rtnStr.Length>10)
					{
						rtnStr = rtnStr + ",A.ROLE";
					}
					else
					{
						rtnStr = rtnStr + "A.ROLE";
					}
				}
				if(this.Chk_StatCondole.Checked)
				{
					if(rtnStr.Length>10)
					{
						rtnStr = rtnStr + ",A.CONDOLENUMBER";
					}
					else
					{
						rtnStr = rtnStr + "A.CONDOLENUMBER";
					}
				}
             
				if(this.Chk_StatResult.Checked)
				{
					if(rtnStr.Length>10)
					{
						rtnStr = rtnStr + ",A.DETERMINANTRESULT";
					}
					else
					{
						rtnStr = rtnStr + "A.DETERMINANTRESULT";
					}
				}
				if(this.Chk_StatSendDate.Checked)
				{
					if(rtnStr.Length>10)
					{
						rtnStr = rtnStr + ",TO_CHAR(A.PICKSTORAGETIME,'YY-MM-DD')";
					}
					else
					{
						rtnStr = rtnStr + "TO_CHAR(A.PICKSTORAGETIME,'YY-MM-DD')";
					}
				}
				if(this.Chk_StatBookInDate.Checked)
				{
					if(rtnStr.Length>10)
					{
						rtnStr = rtnStr + ",TO_CHAR(A.CREATTIME,'YY-MM-DD HH24:MI')";
					}
					else
					{
						rtnStr = rtnStr + "TO_CHAR(A.CREATTIME,'YY-MM-DD HH24:MI')";
					}
				}
				if(this.Chk_StatBookInMan.Checked)
				{
					if(rtnStr.Length>10)
					{
						rtnStr = rtnStr + ",A.CREATOR";
					}
					else
					{
						rtnStr = rtnStr + "A.CREATOR";
					}
				}
				if(this.Chk_StatSendMan.Checked)
				{
					if(rtnStr.Length>10)
					{
						rtnStr = rtnStr + ",A.PICKSTORAGEMAN";
					}
					else
					{
						rtnStr = rtnStr + "A.PICKSTORAGEMAN";
					}
				}
				if(this.Chk_StatBilletID.Checked)
				{
					rtnStr = "";
					rtnList.Add("");
					return rtnList;
				}
				else
				{
					if(rtnStr.Length<=10)
					{
						rtnStr = rtnStr + "C.INCEPTCORPNAME,A.LISTNUMBER,A.STEELTYPE,TO_CHAR(A.PICKSTORAGETIME,'YY-MM-DD')";
					}
				}
				if(this.Chk_StatRole.Checked)
				{
					string tmpstr = "";
					tmpstr = rtnStr + ",A.PLY,A.LENGTH";
					rtnList.Add(tmpstr);
					tmpstr = rtnStr + ",A.PLY,A.WIDTH";
					rtnList.Add(tmpstr);
					tmpstr = rtnStr + ",A.PLY,A.WIDTH,A.LENGTH";
					rtnList.Add(tmpstr);
					tmpstr = rtnStr + ",A.PLY";
					rtnList.Add(tmpstr);
					return rtnList;
				}
				else
				{
					if(this.Chk_StatSpet.Checked)
					{
						rtnStr = rtnStr + ",A.PLY";
					}
					rtnList.Add(rtnStr);
					return  rtnList;
				}
			}
		}
		public System.Collections.ArrayList ClearSendSelectStr
		{
			get
			{
				System.Collections.ArrayList rtnList = new ArrayList();
				string rtnStr = _SelectStr;

				
               
				if(this.chk_SendNo.Checked)
				{
					if(rtnStr.Length>7)
					{
                        rtnStr = rtnStr + ",A.PLANVEHICLEID";
					}
					else
					{
                        rtnStr = rtnStr + "A.PLANVEHICLEID";
					}
				}
               
                if (this.chk_Butress.Checked)
                {
                    if (rtnStr.Length > 7)
                    {
                        rtnStr = rtnStr + ",A.BUTTRESS";
                    }
                    else
                    {
                        rtnStr = rtnStr + "A.BUTTRESS";
                    }
                }
				if(this.chk_CutState.Checked)
				{
					if(rtnStr.Length>7)
					{
						rtnStr = rtnStr + ",(SELECT  NAME_  FROM  SCM_BASE_INFO  WHERE  ID_ = A.CLIPTYPEPROCESS) CLIPTYPEPROCESS";
					}
					else
					{
						rtnStr = rtnStr + "(SELECT  NAME_  FROM  SCM_BASE_INFO  WHERE  ID_ = A.CLIPTYPEPROCESS) CLIPTYPEPROCESS";
					}
				}

				if(this.chk_ProcLine.Checked)
				{
					if(rtnStr.Length>7)
					{
						rtnStr = rtnStr + ",(SELECT  NAME_  FROM  SCM_BASE_INFO  WHERE  ID_ = B.PRODLINECODE) PRODLINECODE";
					}
					else
					{
						rtnStr = rtnStr + "(SELECT  NAME_  FROM  SCM_BASE_INFO  WHERE  ID_ = B.PRODLINECODE) PRODLINECODE";
					}
				}

				if(this.chk_StatInceName.Checked)
				{
					if(rtnStr.Length>7)
					{
						rtnStr = rtnStr + ",C.INCEPTCORPNAME";
					}
					else
					{
						rtnStr = rtnStr + "C.INCEPTCORPNAME";
					}
				}
				if(this.Chk_StatListCoding.Checked)
				{
					if(rtnStr.Length>7)
					{
						rtnStr = rtnStr + ",A.LISTNUMBER";
					}
					else
					{
						rtnStr = rtnStr + "A.LISTNUMBER";
					}
				}
				if(this.Chk_StatVecihleNO.Checked)
				{
					if(rtnStr.Length>7)
					{
						rtnStr = rtnStr + ",A.TRAINWAGON";
					}
					else
					{
						rtnStr = rtnStr + "A.TRAINWAGON";
					}
				}
              
              
				if(this.chk_StatStation.Checked)
				{
					if(rtnStr.Length>7)
					{
						rtnStr = rtnStr + ",D.STATIONNAME";
					}
					else
					{
						rtnStr = rtnStr + "D.STATIONNAME";
					}
				}
				if(this.Chk_StatPactNO.Checked)
				{
					if(rtnStr.Length>7)
					{
						rtnStr = rtnStr + ",B.PACTNO";
					}
					else
					{
						rtnStr = rtnStr + "B.PACTNO";
					}
				}
				if(this.chk_StatOrder.Checked)
				{
					if(rtnStr.Length>7)
					{
						rtnStr = rtnStr + ",A.ORDERFORMNUMBER";
					}
					else
					{
						rtnStr = rtnStr + "A.ORDERFORMNUMBER";
					}
				}
				if(this.Chk_StatPlanNO.Checked)
				{
					if(rtnStr.Length>7)
					{
						rtnStr = rtnStr + ",A.PLANNO";
					}
					else
					{
						rtnStr = rtnStr + "A.PLANNO";
					}
				}
				if(this.Chk_StatSteel.Checked)
				{
					if(rtnStr.Length>7)
					{
						rtnStr = rtnStr + ",A.STEELTYPE";
					}
					else
					{
						rtnStr = rtnStr + "A.STEELTYPE";
					}
				}
				if(this.Chk_StatRollNO.Checked)
				{
					if(rtnStr.Length>7)
					{
						rtnStr = rtnStr + ",A.ROLLNO";
					}
					else
					{
						rtnStr = rtnStr + "A.ROLLNO";
					}
				}
				if(this.Chk_StatClassTeam.Checked)
				{
					if(rtnStr.Length>7)
					{
						rtnStr = rtnStr + ",(SELECT NAME_ FROM SCM_BASE_INFO WHERE ID_=A.CLASSTEAM) CLASSTEAM";
					}
					else
					{
						rtnStr = rtnStr + "(SELECT NAME_ FROM SCM_BASE_INFO WHERE ID_=A.CLASSTEAM) CLASSTEAM";
					}
				}
				
				if(this.Chk_StatRole.Checked)
				{
					if(rtnStr.Length>7)
					{
						rtnStr = rtnStr+ ",(SELECT NAME_ FROM SCM_BASE_INFO WHERE ID_=A.ROLE) ROLE";
					}
					else
					{
						rtnStr = rtnStr+ "(SELECT NAME_ FROM SCM_BASE_INFO WHERE ID_=A.ROLE) ROLE";
					}
				}
				if(this.Chk_StatCondole.Checked)
				{
					if(rtnStr.Length>7)
					{
						rtnStr = rtnStr + ",A.CONDOLENUMBER";
					}
					else
					{
						rtnStr = rtnStr + "A.CONDOLENUMBER";
					}
				}
				if(this.Chk_StatResult.Checked)
				{
					if(rtnStr.Length>7)
					{
						rtnStr = rtnStr + ",(SELECT NAME_ FROM SCM_BASE_INFO WHERE ID_=A.DETERMINANTRESULT) DETERMINANTRESULT";
					}
					else
					{
						rtnStr = rtnStr + "(SELECT NAME_ FROM SCM_BASE_INFO WHERE ID_=A.DETERMINANTRESULT) DETERMINANTRESULT";
					}
				}
				if(this.Chk_StatSendDate.Checked)
				{
					if(rtnStr.Length>7)
					{
						rtnStr = rtnStr + ",TO_CHAR(A.PICKSTORAGETIME,'YY-MM-DD') PICKSTORAGETIME";
					}
					else
					{
						rtnStr = rtnStr + "TO_CHAR(A.PICKSTORAGETIME,'YY-MM-DD') PICKSTORAGETIME";
					}
				}
				if(this.Chk_StatBookInDate.Checked)
				{
					if(rtnStr.Length>7)
					{
						rtnStr = rtnStr + ",TO_CHAR(A.CREATTIME,'YY-MM-DD HH24:MI') CREATTIME";
					}
					else
					{
						rtnStr = rtnStr + "TO_CHAR(A.CREATTIME,'YY-MM-DD HH24:MI') CREATTIME";
					}
				}
				if(this.Chk_StatBookInMan.Checked)
				{
					if(rtnStr.Length>7)
					{
						rtnStr = rtnStr + ",A.CREATOR";
					}
					else
					{
						rtnStr = rtnStr + "A.CREATOR";
					}
				}
				if(this.Chk_StatSendMan.Checked)
				{
					if(rtnStr.Length>7)
					{
						rtnStr = rtnStr + ",A.PICKSTORAGEMAN";
					}
					else
					{
						rtnStr = rtnStr + "A.PICKSTORAGEMAN";
					}
				}
				if(this.Chk_StatBilletID.Checked)
				{
					if(rtnStr.Length>7)
					{
						rtnStr = rtnStr + ",A.SERIALNUMBER,1 QUANTITY,A.WEIGHT,A.ADDWEIGHT,A.ACREAGE ";
					}
					else
					{
						rtnStr = rtnStr + "C.INCEPTCORPNAME,A.LISTNUMBER,A.STEELTYPE,TO_CHAR(A.PICKSTORAGETIME,'YY-MM-DD') PICKSTORAGETIME,A.SERIALNUMBER,1 QUANTITY,A.WEIGHT,A.ADDWEIGHT,A.ACREAGE ";
					}
					rtnStr = rtnStr + ",TO_CHAR(A.PLY)||'×'||TO_CHAR(A.WIDTH)||'×'||TO_CHAR(A.LENGTH) SPET";
					
					rtnList.Add(rtnStr);
					return rtnList;
				}
				else
				{
					if(rtnStr.Length>7)
					{
						rtnStr = rtnStr + ",COUNT(A.SERIALNUMBER) QUANTITY,SUM(A.WEIGHT) WEIGHT,SUM(A.ADDWEIGHT) ADDWEIGHT,SUM(A.ACREAGE) ACREAGE "; 
					}
					else
					{
						rtnStr = rtnStr + "C.INCEPTCORPNAME,A.LISTNUMBER,A.STEELTYPE,TO_CHAR(A.PICKSTORAGETIME,'YY-MM-DD') PICKSTORAGETIME,COUNT(A.SERIALNUMBER) QUANTITY,SUM(A.WEIGHT) WEIGHT,SUM(A.ADDWEIGHT) ADDWEIGHT,SUM(A.ACREAGE) ACREAGE "; 
					}
				}
				if(this.Chk_StatRole.Checked)
				{
					string tmpstr = "";
					tmpstr = rtnStr + ",TO_CHAR(A.PLY)||'×'||TO_CHAR(A.LENGTH) SPET ";       //定长
					
					rtnList.Add(tmpstr);
					tmpstr = rtnStr + ",TO_CHAR(A.PLY)||'×'||TO_CHAR(A.WIDTH) SPET ";      //定宽
					
					rtnList.Add(tmpstr);
					tmpstr = rtnStr + ",TO_CHAR(A.PLY)||'×'||TO_CHAR(A.WIDTH)||'×'||TO_CHAR(A.LENGTH) SPET ";      //双定
					
					rtnList.Add(tmpstr);
					tmpstr = rtnStr + ",TO_CHAR(A.PLY) SPET ";      //非定
					
					rtnList.Add(tmpstr);
					return rtnList;
				}
				else
				{
					if(this.Chk_StatSpet.Checked)
					{
						rtnStr = rtnStr + ",TO_CHAR(A.PLY) SPET ";
					}
					
					rtnList.Add(rtnStr);
					return rtnList;
				}
			}
		}
		



        
       
		#endregion
	}
}
