Example #1
0
        private void Batch_Load(object sender, EventArgs e)
        {
            CommonMethod.RefreshAndAutoSize(ultraGrid1);
            CommonMethod.RefreshAndAutoSize(ultraGrid2);

            try
            {
                dateTimePicker1.Value = DateTime.Today;
                dateTimePicker2.Value = DateTime.Today.AddDays(1).AddSeconds(-1);
            }
            catch (Exception ex)
            {
                Debug.WriteLine(ex.Message);
            }

            try
            {
                string strKey = this.CustomInfo.ToUpper();

                if (!string.IsNullOrEmpty(strKey) && strKey.Length == 2)
                {
                    if (strKey.Substring(0, 2).Equals("GX"))
                    {
                        this._STOCK       = "SH000100";
                        this._PRODUCELINE = ProduceLine.GX;
                        CodeType.Visible  = false;
                    }
                    else if (strKey.Substring(0, 2).Equals("BC"))
                    {
                        this._STOCK       = "SH000098";
                        this._PRODUCELINE = ProduceLine.BC;
                        CodeType.Visible  = false;
                    }
                    else if (strKey.Substring(0, 2).Equals("XC"))
                    {
                        this._STOCK       = "SH000120";                                            //型材未知
                        this._PRODUCELINE = ProduceLine.XC;
                        CodeType.Visible  = true;
                    }
                }
            }
            catch (Exception ex)
            {
                Debug.WriteLine(ex.Message);
            }

            this.GetBatchInfo(QueryOpportunity.UI);
            this.GetStockInfo(QueryOpportunity.AfterOpt);
        }
Example #2
0
        public frmSetSpec(ProduceLine ProdLine, CodeType_XC CodeType, bool Success, string BatchNo, string OrderNo, string Spec, string Length)
        {
            InitializeComponent();

            this._LastBatchNo = BatchNo;
            this._LastOrderNo = OrderNo;
            this._LastSpec    = Spec;
            this._LastLength  = Length;
            this._LastSuccess = Success;

            this._CODETYPE    = CodeType;
            this._PRODUCELINE = ProdLine;

            if (_PRODUCELINE == ProduceLine.GX)
            {
                Edt_Length.Clear();
                Edt_Length.Enabled = false;
            }
        }
Example #3
0
        public frmSetSpec(ProduceLine ProdLine, CodeType_XC CodeType, bool Success, string BatchNo, string OrderNo, string Spec, string Length)
        {
            InitializeComponent();

            this._LastBatchNo = BatchNo;
            this._LastOrderNo = OrderNo;
            this._LastSpec = Spec;
            this._LastLength = Length;
            this._LastSuccess = Success;

            this._CODETYPE = CodeType;
            this._PRODUCELINE = ProdLine;

            if (_PRODUCELINE == ProduceLine.GX)
            {
                Edt_Length.Clear();
                Edt_Length.Enabled = false;
            }
        }
Example #4
0
        public void SetPost_Rolling(ProduceLine ProLine)
        {
            try
            {
                ArrayList alistEditable = new ArrayList();

                alistEditable.Add("FN_ZZ_SPEC");
                if (ProLine != ProduceLine.GX)
                {
                    alistEditable.Add("FN_LENGTH");
                }
                alistEditable.Add("FD_ZZ_DATE");
                alistEditable.Add("FN_ZZ_NUM");
                alistEditable.Add("FN_ZZ_WASTNUM");
                alistEditable.Add("FS_ZZ_MEMO");

                CommonMethod.SetUltraGridCellEditable(ref ultraGrid1, alistEditable);

                ultraGrid1.ActiveCell = ultraGrid1.Rows[0].Cells["FN_ZZ_SPEC"];
                ultraGrid1.PerformAction(UltraGridAction.EnterEditMode);
            }
            catch { }
        }
Example #5
0
        public void SetPost_Rolling(ProduceLine ProLine)
        {
            try
            {
                ArrayList alistEditable = new ArrayList();

                alistEditable.Add("FN_ZZ_SPEC");
                if (ProLine != ProduceLine.GX)
                    alistEditable.Add("FN_LENGTH");
                alistEditable.Add("FD_ZZ_DATE");
                alistEditable.Add("FN_ZZ_NUM");
                alistEditable.Add("FN_ZZ_WASTNUM");
                alistEditable.Add("FS_ZZ_MEMO");

                CommonMethod.SetUltraGridCellEditable(ref ultraGrid1, alistEditable);

                ultraGrid1.ActiveCell = ultraGrid1.Rows[0].Cells["FN_ZZ_SPEC"];
                ultraGrid1.PerformAction(UltraGridAction.EnterEditMode);
            }
            catch { }
        }
Example #6
0
        public bool DataValidation_Rolling(ProduceLine ProLine, out Hashtable htblValue)
        {
            htblValue = new Hashtable();

            try
            {
                if (ultraGrid1.Rows.Count == 0)
                {
                    return false;
                }

                ultraGrid1.UpdateData();

                string strValue = Convert.ToString(ultraGrid1.Rows[0].Cells["FN_ZZ_SPEC"].Value).Trim();

                if (string.IsNullOrEmpty(strValue))
                {
                    MessageBox.Show("请输入轧制规格!", "提示", MessageBoxButtons.OK, MessageBoxIcon.Asterisk);
                    CommonMethod.SetUltraGridActiveCell(ref ultraGrid1, 0, "FN_ZZ_SPEC", true);
                    return false;
                }

                int iCount = 0;
                decimal dCount = 0.0M;
                bool bOK = false;

                if (ProLine != ProduceLine.GX)
                {
                    strValue = Convert.ToString(ultraGrid1.Rows[0].Cells["FN_LENGTH"].Value).Trim();

                    if (string.IsNullOrEmpty(strValue))
                    {
                        MessageBox.Show("请输入定尺长度!", "提示", MessageBoxButtons.OK, MessageBoxIcon.Asterisk);
                        CommonMethod.SetUltraGridActiveCell(ref ultraGrid1, 0, "FN_LENGTH", true);
                        return false;
                    }

                    bOK = int.TryParse(strValue, out iCount);

                    if (!bOK)
                    {
                        MessageBox.Show("定尺长度必须是整数!", "提示", MessageBoxButtons.OK, MessageBoxIcon.Asterisk);
                        CommonMethod.SetUltraGridActiveCell(ref ultraGrid1, 0, "FN_LENGTH", true);
                        return false;
                    }

                    if (iCount < 0)
                    {
                        MessageBox.Show("定尺长度必须大于零!", "提示", MessageBoxButtons.OK, MessageBoxIcon.Asterisk);
                        CommonMethod.SetUltraGridActiveCell(ref ultraGrid1, 0, "FN_LENGTH", true);
                        return false;
                    }
                }

                strValue = Convert.ToString(ultraGrid1.Rows[0].Cells["FN_ZZ_NUM"].Value).Trim();

                if (string.IsNullOrEmpty(strValue))
                {
                    MessageBox.Show("请输入成材条数!", "提示", MessageBoxButtons.OK, MessageBoxIcon.Asterisk);
                    CommonMethod.SetUltraGridActiveCell(ref ultraGrid1, 0, "FN_ZZ_NUM", true);
                    return false;
                }

                bOK = decimal.TryParse(strValue, out dCount);

                if (!bOK)
                {
                    MessageBox.Show("成材条数必须是数值!", "提示", MessageBoxButtons.OK, MessageBoxIcon.Asterisk);
                    CommonMethod.SetUltraGridActiveCell(ref ultraGrid1, 0, "FN_ZZ_NUM", true);
                    return false;
                }

                if (dCount < 0)
                {
                    MessageBox.Show("成材条数必须大于零!", "提示", MessageBoxButtons.OK, MessageBoxIcon.Asterisk);
                    CommonMethod.SetUltraGridActiveCell(ref ultraGrid1, 0, "FN_ZZ_NUM", true);
                    return false;
                }

                strValue = Convert.ToString(ultraGrid1.Rows[0].Cells["FN_ZZ_WASTNUM"].Value).Trim();

                if (!string.IsNullOrEmpty(strValue))
                {
                    bOK = decimal.TryParse(strValue, out dCount);

                    if (!bOK)
                    {
                        MessageBox.Show("轧废条数必须是数值!", "提示", MessageBoxButtons.OK, MessageBoxIcon.Asterisk);
                        CommonMethod.SetUltraGridActiveCell(ref ultraGrid1, 0, "FN_ZZ_WASTNUM", true);
                        return false;
                    }

                    if (dCount < 0)
                    {
                        MessageBox.Show("轧废条数必须大于零!", "提示", MessageBoxButtons.OK, MessageBoxIcon.Asterisk);
                        CommonMethod.SetUltraGridActiveCell(ref ultraGrid1, 0, "FN_ZZ_WASTNUM", true);
                        return false;
                    }
                }

                strValue = Convert.ToString(ultraGrid1.Rows[0].Cells["FN_ZZ_SPEC"].Text).Trim();
                htblValue.Add("V2", strValue);           //轧制规格
                strValue = Convert.ToString(ultraGrid1.Rows[0].Cells["FN_LENGTH"].Text).Trim();
                htblValue.Add("V3", strValue);           //定尺长度
                strValue = Convert.ToString(ultraGrid1.Rows[0].Cells["FD_ZZ_DATE"].Text).Trim();
                htblValue.Add("V4", strValue);           //轧制时间
                strValue = Convert.ToString(ultraGrid1.Rows[0].Cells["FN_ZZ_NUM"].Text).Trim();
                htblValue.Add("V5", strValue);           //成材支数
                strValue = Convert.ToString(ultraGrid1.Rows[0].Cells["FN_ZZ_WASTNUM"].Text).Trim();
                htblValue.Add("V6", strValue);           //轧废支数
                strValue = Convert.ToString(ultraGrid1.Rows[0].Cells["FS_ZZ_MEMO"].Text).Trim();
                htblValue.Add("V8", strValue);           //轧废支数

                return true;
            }
            catch { }

            return false;
        }
Example #7
0
        public bool DataValidation_Rolling(ProduceLine ProLine, out Hashtable htblValue)
        {
            htblValue = new Hashtable();

            try
            {
                if (ultraGrid1.Rows.Count == 0)
                {
                    return(false);
                }

                ultraGrid1.UpdateData();

                string strValue = Convert.ToString(ultraGrid1.Rows[0].Cells["FN_ZZ_SPEC"].Value).Trim();

                if (string.IsNullOrEmpty(strValue))
                {
                    MessageBox.Show("请输入轧制规格!", "提示", MessageBoxButtons.OK, MessageBoxIcon.Asterisk);
                    CommonMethod.SetUltraGridActiveCell(ref ultraGrid1, 0, "FN_ZZ_SPEC", true);
                    return(false);
                }

                int     iCount = 0;
                decimal dCount = 0.0M;
                bool    bOK    = false;

                if (ProLine != ProduceLine.GX)
                {
                    strValue = Convert.ToString(ultraGrid1.Rows[0].Cells["FN_LENGTH"].Value).Trim();

                    if (string.IsNullOrEmpty(strValue))
                    {
                        MessageBox.Show("请输入定尺长度!", "提示", MessageBoxButtons.OK, MessageBoxIcon.Asterisk);
                        CommonMethod.SetUltraGridActiveCell(ref ultraGrid1, 0, "FN_LENGTH", true);
                        return(false);
                    }

                    bOK = int.TryParse(strValue, out iCount);

                    if (!bOK)
                    {
                        MessageBox.Show("定尺长度必须是整数!", "提示", MessageBoxButtons.OK, MessageBoxIcon.Asterisk);
                        CommonMethod.SetUltraGridActiveCell(ref ultraGrid1, 0, "FN_LENGTH", true);
                        return(false);
                    }

                    if (iCount < 0)
                    {
                        MessageBox.Show("定尺长度必须大于零!", "提示", MessageBoxButtons.OK, MessageBoxIcon.Asterisk);
                        CommonMethod.SetUltraGridActiveCell(ref ultraGrid1, 0, "FN_LENGTH", true);
                        return(false);
                    }
                }

                strValue = Convert.ToString(ultraGrid1.Rows[0].Cells["FN_ZZ_NUM"].Value).Trim();

                if (string.IsNullOrEmpty(strValue))
                {
                    MessageBox.Show("请输入成材条数!", "提示", MessageBoxButtons.OK, MessageBoxIcon.Asterisk);
                    CommonMethod.SetUltraGridActiveCell(ref ultraGrid1, 0, "FN_ZZ_NUM", true);
                    return(false);
                }

                bOK = decimal.TryParse(strValue, out dCount);

                if (!bOK)
                {
                    MessageBox.Show("成材条数必须是数值!", "提示", MessageBoxButtons.OK, MessageBoxIcon.Asterisk);
                    CommonMethod.SetUltraGridActiveCell(ref ultraGrid1, 0, "FN_ZZ_NUM", true);
                    return(false);
                }

                if (dCount < 0)
                {
                    MessageBox.Show("成材条数必须大于零!", "提示", MessageBoxButtons.OK, MessageBoxIcon.Asterisk);
                    CommonMethod.SetUltraGridActiveCell(ref ultraGrid1, 0, "FN_ZZ_NUM", true);
                    return(false);
                }

                strValue = Convert.ToString(ultraGrid1.Rows[0].Cells["FN_ZZ_WASTNUM"].Value).Trim();

                if (!string.IsNullOrEmpty(strValue))
                {
                    bOK = decimal.TryParse(strValue, out dCount);

                    if (!bOK)
                    {
                        MessageBox.Show("轧废条数必须是数值!", "提示", MessageBoxButtons.OK, MessageBoxIcon.Asterisk);
                        CommonMethod.SetUltraGridActiveCell(ref ultraGrid1, 0, "FN_ZZ_WASTNUM", true);
                        return(false);
                    }

                    if (dCount < 0)
                    {
                        MessageBox.Show("轧废条数必须大于零!", "提示", MessageBoxButtons.OK, MessageBoxIcon.Asterisk);
                        CommonMethod.SetUltraGridActiveCell(ref ultraGrid1, 0, "FN_ZZ_WASTNUM", true);
                        return(false);
                    }
                }

                strValue = Convert.ToString(ultraGrid1.Rows[0].Cells["FN_ZZ_SPEC"].Text).Trim();
                htblValue.Add("V2", strValue);           //轧制规格
                strValue = Convert.ToString(ultraGrid1.Rows[0].Cells["FN_LENGTH"].Text).Trim();
                htblValue.Add("V3", strValue);           //定尺长度
                strValue = Convert.ToString(ultraGrid1.Rows[0].Cells["FD_ZZ_DATE"].Text).Trim();
                htblValue.Add("V4", strValue);           //轧制时间
                strValue = Convert.ToString(ultraGrid1.Rows[0].Cells["FN_ZZ_NUM"].Text).Trim();
                htblValue.Add("V5", strValue);           //成材支数
                strValue = Convert.ToString(ultraGrid1.Rows[0].Cells["FN_ZZ_WASTNUM"].Text).Trim();
                htblValue.Add("V6", strValue);           //轧废支数
                strValue = Convert.ToString(ultraGrid1.Rows[0].Cells["FS_ZZ_MEMO"].Text).Trim();
                htblValue.Add("V8", strValue);           //轧废支数

                return(true);
            }
            catch { }

            return(false);
        }
Example #8
0
        private void BilletFlowCard_Load(object sender, EventArgs e)
        {
            CommonMethod.RefreshAndAutoSize(ultraGrid1);

            try
            {
                dateTimePicker1.Value = DateTime.Today;
                dateTimePicker2.Value = DateTime.Today.AddDays(1).AddSeconds(-1);
            }
            catch (Exception ex)
            {
                Debug.WriteLine(ex.Message);
            }

            try
            {
                string strKey = this.CustomInfo.ToUpper();

                if (!string.IsNullOrEmpty(strKey))
                {
                    if (strKey.Substring(0, 3).Equals("ZKD"))
                    {
                        this._STOCK       = "SH000100";
                        this._PRODUCELINE = ProduceLine.ZKD;
                    }
                    else if (strKey.Substring(0, 2).Equals("BC"))
                    {
                        this._STOCK       = "SH000098";
                        this._PRODUCELINE = ProduceLine.BC;
                    }
                    else if (strKey.Substring(0, 2).Equals("XC"))
                    {
                        this._STOCK       = "SH000120";                                            //型材未知
                        this._PRODUCELINE = ProduceLine.XC;
                    }

                    if (strKey.Substring(3, 1).Equals("1"))
                    {
                        this._POST = Post.Receive;
                        ucBilletFlowCard1.SetPost_BilletReceive();
                        SetToolButtonCaption("Save", "验收登记");
                        SetToolButtonCaption("Cancel", "撤销验收");
                        SetToolButtonCaption("开始", "分析时间");
                        SetToolButtonCaption("轧制编号", "  货架编号");
                        SetToolButtonVisible("其他库1", false);
                        SetToolButtonVisible("其他库2", false);
                        SetToolButtonVisible("其他库3", false);
                        SetToolButtonVisible("出炉结束", false);
                        SetToolButtonVisible("取消结束", false);
                        SetToolButtonVisible("置为返回坯", false);
                        rbtnA.Text          = "未验收";
                        rbtnB.Text          = "已验收";
                        cbxDateTime.Checked = false;
                        lbl_Mark.Text       = "此颜色表示已验收登记";
                    }
                    else if (strKey.Substring(3, 1).Equals("2"))
                    {
                        this._POST = Post.Charge;
                        ucBilletFlowCard1.SetPost_Charge();
                        SetToolButtonCaption("Save", "入炉登记");
                        SetToolButtonCaption("Cancel", "撤销入炉");
                        SetToolButtonCaption("开始", "组批时间");
                        SetToolButtonCaption("轧制编号", "  轧制编号");
                        SetToolButtonVisible("其他库1", false);
                        SetToolButtonVisible("其他库2", false);
                        SetToolButtonVisible("其他库3", false);
                        SetToolButtonVisible("出炉结束", false);
                        SetToolButtonVisible("取消结束", false);
                        SetToolButtonVisible("置为返回坯", false);
                        rbtnA.Text          = "未入炉";
                        rbtnB.Text          = "已入炉";
                        cbxDateTime.Checked = true;
                        lbl_Mark.Text       = "此颜色表示已入炉登记";
                    }
                    else if (strKey.Substring(3, 1).Equals("3"))
                    {
                        this._POST = Post.DisCharge;
                        ultraExpandableGroupBox1.Visible = false;
                        SetToolButtonCaption("Save", "出炉开始");
                        SetToolButtonCaption("Cancel", "撤销开始");
                        SetToolButtonCaption("开始", "组批时间");
                        SetToolButtonCaption("轧制编号", "  轧制编号");
                        SetToolButtonVisible("其他库1", false);
                        SetToolButtonVisible("其他库2", false);
                        SetToolButtonVisible("其他库3", false);
                        SetToolButtonVisible("出炉结束", true);
                        SetToolButtonVisible("取消结束", true);
                        rbtnA.Text             = "未出炉";
                        rbtnB.Text             = "已出炉";
                        rbtnC.Checked          = true;
                        cbxDateTime.Checked    = true;
                        lbl_Mark.Text          = "此颜色表示已出炉登记";
                        lbl_InFurnance.Text    = "此颜色表示正在出炉";
                        lbl_InFurnance.Visible = true;
                    }
                    else if (strKey.Substring(3, 1).Equals("4"))
                    {
                        this._POST = Post.Roll;
                        ucBilletFlowCard1.SetPost_Rolling(_PRODUCELINE);
                        SetToolButtonCaption("Save", "保存");
                        SetToolButtonCaption("Cancel", "撤销");
                        SetToolButtonCaption("开始", "组批时间");
                        SetToolButtonCaption("轧制编号", "  轧制编号");
                        SetToolButtonVisible("其他库1", false);
                        SetToolButtonVisible("其他库2", false);
                        SetToolButtonVisible("其他库3", false);
                        SetToolButtonVisible("出炉结束", false);
                        SetToolButtonVisible("取消结束", false);
                        SetToolButtonVisible("置为返回坯", false);
                        rbtnA.Text          = "未挑废";
                        rbtnB.Text          = "已挑废";
                        cbxDateTime.Checked = true;
                        lbl_Mark.Text       = "此颜色表示已挑废登记";
                    }
                }
            }
            catch (Exception ex)
            {
                Debug.WriteLine(ex.Message);
            }
        }
Example #9
0
        private void BilletFlowCard_Load(object sender, EventArgs e)
        {
            CommonMethod.RefreshAndAutoSize(ultraGrid1);

            try
            {
                dateTimePicker1.Value = DateTime.Today;
                dateTimePicker2.Value = DateTime.Today.AddDays(1).AddSeconds(-1);
            }
            catch (Exception ex)
            {
                Debug.WriteLine(ex.Message);
            }

            try
            {
                string strKey = this.CustomInfo.ToUpper();

                if (!string.IsNullOrEmpty(strKey))
                {
                    if (strKey.Substring(0, 3).Equals("ZKD"))
                    {
                        this._STOCK = "SH000100";
                        this._PRODUCELINE = ProduceLine.ZKD;
                    }
                    else if (strKey.Substring(0, 2).Equals("BC"))
                    {
                        this._STOCK = "SH000098";
                        this._PRODUCELINE = ProduceLine.BC;
                    }
                    else if (strKey.Substring(0, 2).Equals("XC"))
                    {
                        this._STOCK = "SH000120";                                                  //�Ͳ�δ֪
                        this._PRODUCELINE = ProduceLine.XC;
                    }

                    if (strKey.Substring(3, 1).Equals("1"))
                    {
                        this._POST = Post.Receive;
                        ucBilletFlowCard1.SetPost_BilletReceive();
                        SetToolButtonCaption("Save", "���յǼ�");
                        SetToolButtonCaption("Cancel", "��������");
                        SetToolButtonCaption("��ʼ", "����ʱ��");
                        SetToolButtonCaption("���Ʊ��", "�������ܱ��");
                        SetToolButtonVisible("������1", false);
                        SetToolButtonVisible("������2", false);
                        SetToolButtonVisible("������3", false);
                        SetToolButtonVisible("��¯����", false);
                        SetToolButtonVisible("ȡ������", false);
                        SetToolButtonVisible("��������", false);
                        rbtnA.Text = "���";
                        rbtnB.Text = "������";
                        cbxDateTime.Checked = false;
                        lbl_Mark.Text = "����ɫ��ʾ�����յǼ�";
                    }
                    else if (strKey.Substring(3, 1).Equals("2"))
                    {
                        this._POST = Post.Charge;
                        ucBilletFlowCard1.SetPost_Charge();
                        SetToolButtonCaption("Save", "��¯�Ǽ�");
                        SetToolButtonCaption("Cancel", "������¯");
                        SetToolButtonCaption("��ʼ", "����ʱ��");
                        SetToolButtonCaption("���Ʊ��", "�������Ʊ��");
                        SetToolButtonVisible("������1", false);
                        SetToolButtonVisible("������2", false);
                        SetToolButtonVisible("������3", false);
                        SetToolButtonVisible("��¯����", false);
                        SetToolButtonVisible("ȡ������", false);
                        SetToolButtonVisible("��������", false);
                        rbtnA.Text = "δ��¯";
                        rbtnB.Text = "����¯";
                        cbxDateTime.Checked = true;
                        lbl_Mark.Text = "����ɫ��ʾ����¯�Ǽ�";
                    }
                    else if (strKey.Substring(3, 1).Equals("3"))
                    {
                        this._POST = Post.DisCharge;
                        ultraExpandableGroupBox1.Visible = false;
                        SetToolButtonCaption("Save", "��¯��ʼ");
                        SetToolButtonCaption("Cancel", "������ʼ");
                        SetToolButtonCaption("��ʼ", "����ʱ��");
                        SetToolButtonCaption("���Ʊ��", "�������Ʊ��");
                        SetToolButtonVisible("������1", false);
                        SetToolButtonVisible("������2", false);
                        SetToolButtonVisible("������3", false);
                        SetToolButtonVisible("��¯����", true);
                        SetToolButtonVisible("ȡ������", true);
                        rbtnA.Text = "δ��¯";
                        rbtnB.Text = "�ѳ�¯";
                        rbtnC.Checked = true;
                        cbxDateTime.Checked = true;
                        lbl_Mark.Text = "����ɫ��ʾ�ѳ�¯�Ǽ�";
                        lbl_InFurnance.Text = "����ɫ��ʾ���ڳ�¯";
                        lbl_InFurnance.Visible = true;
                    }
                    else if (strKey.Substring(3, 1).Equals("4"))
                    {
                        this._POST = Post.Roll;
                        ucBilletFlowCard1.SetPost_Rolling(_PRODUCELINE);
                        SetToolButtonCaption("Save", "����");
                        SetToolButtonCaption("Cancel", "����");
                        SetToolButtonCaption("��ʼ", "����ʱ��");
                        SetToolButtonCaption("���Ʊ��", "�������Ʊ��");
                        SetToolButtonVisible("������1", false);
                        SetToolButtonVisible("������2", false);
                        SetToolButtonVisible("������3", false);
                        SetToolButtonVisible("��¯����", false);
                        SetToolButtonVisible("ȡ������", false);
                        SetToolButtonVisible("��������", false);
                        rbtnA.Text = "��";
                        rbtnB.Text = "�����";
                        cbxDateTime.Checked = true;
                        lbl_Mark.Text = "����ɫ��ʾ����ϵǼ�";
                    }
                }
            }
            catch (Exception ex)
            {
                Debug.WriteLine(ex.Message);
            }
        }
Example #10
0
        private void Batch_Load(object sender, EventArgs e)
        {
            CommonMethod.RefreshAndAutoSize(ultraGrid1);
            CommonMethod.RefreshAndAutoSize(ultraGrid2);

            try
            {
                dateTimePicker1.Value = DateTime.Today;
                dateTimePicker2.Value = DateTime.Today.AddDays(1).AddSeconds(-1);
            }
            catch (Exception ex)
            {
                Debug.WriteLine(ex.Message);
            }

            try
            {
                string strKey = this.CustomInfo.ToUpper();

                if (!string.IsNullOrEmpty(strKey) && strKey.Length == 2)
                {
                    if (strKey.Substring(0, 2).Equals("GX"))
                    {
                        this._STOCK = "SH000100";
                        this._PRODUCELINE = ProduceLine.GX;
                        CodeType.Visible = false;
                    }
                    else if (strKey.Substring(0, 2).Equals("BC"))
                    {
                        this._STOCK = "SH000098";
                        this._PRODUCELINE = ProduceLine.BC;
                        CodeType.Visible = false;
                    }
                    else if (strKey.Substring(0, 2).Equals("XC"))
                    {
                        this._STOCK = "SH000120";                                                  //�Ͳ�δ֪
                        this._PRODUCELINE = ProduceLine.XC;
                        CodeType.Visible = true;
                    }
                }
            }
            catch (Exception ex)
            {
                Debug.WriteLine(ex.Message);
            }

            this.GetBatchInfo(QueryOpportunity.UI);
            this.GetStockInfo(QueryOpportunity.AfterOpt);
        }