示例#1
0
        private void cmbRawSecond_SelectedIndexChanged(object sender, EventArgs e)
        {
            //初始化,全部处于未激活
            this.SetComponentDisabled();

            if (this.cmbRawSecond.SelectedValue.ToString().Length > 5)
            {
                return;                                                        //处理冲突,启动时会激活该事件报错
            }
            if (this.cmbRawSecond.SelectedValue.ToString() == "2" && this.cmbRawFirst.SelectedValue.ToString() == "1")
            {
                //非金属,材料牌号,厚度和长宽激活输入
                this.SetTxtRawEnabled();
                this.SetTxtThickAndTxtSizeEnabled();
            }

            //级联变化
            LevelSearchor.searchAndSetLevel3(this.cmbRawThird,
                                             "1",
                                             this.cmbRawFirst.SelectedValue.ToString(),
                                             this.cmbRawSecond.SelectedValue.ToString());

            //SetTxtCodeNull();
            GenerateLevelCode();
        }
示例#2
0
 private void cmbContractFirst_SelectedIndexChanged(object sender, EventArgs e)
 {
     if (this.cmbContractFirst.SelectedValue.ToString().Length > 5)
     {
         return;                                                            //处理冲突,启动时会激活该事件报错
     }
     //设置下级下拉框的级联变化
     LevelSearchor.searchAndSetLevel2(this.cmbContractSecond, "2", this.cmbContractFirst.SelectedValue.ToString());
     GenerateContractCode();
 }
示例#3
0
 private void cmbStdFirst_SelectedIndexChanged(object sender, EventArgs e)
 {
     setStdComponentDisable();
     if (this.cmbStdFirst.SelectedValue.ToString().Length > 5)
     {
         return;                                                       //处理冲突,启动时会激活该事件报错
     }
     //设置下级下拉框的级联变化
     LevelSearchor.searchAndSetLevel2(this.cmbStdSecond, "2", this.cmbStdFirst.SelectedValue.ToString());
     GenerateStdLevelCode();
 }
示例#4
0
        private void cmbRawFirst_SelectedIndexChanged(object sender, EventArgs e)
        {
            //初始化,全部处于未激活
            this.SetComponentDisabled();

            if (this.cmbRawFirst.SelectedValue.ToString().Length > 5)
            {
                return;                                                       //处理冲突,启动时会激活该事件报错
            }
            //设置下级下拉框的级联变化
            LevelSearchor.searchAndSetLevel2(this.cmbRawSecond, "1", this.cmbRawFirst.SelectedValue.ToString());
            //SetTxtCodeNull();
            GenerateLevelCode();
        }
示例#5
0
        private void cmbElecFirst_SelectedIndexChanged(object sender, EventArgs e)
        {
            this.setElecComponentDisalbe();
            if (this.cmbElecFirst.SelectedValue.ToString().Length > 5)
            {
                return;                                                        //处理冲突,启动时会激活该事件报错
            }
            //设置下级下拉框的级联变化
            LevelSearchor.searchAndSetLevel2(this.cmbElecSecond, "3", this.cmbElecFirst.SelectedValue.ToString());

            //根据选择,决定激活哪些控件
            SetEnableAdjustToInput();

            //实时生成编码
            GenerateAllCode();
        }
示例#6
0
        private void cmbMlineFirst_SelectedIndexChanged(object sender, EventArgs e)
        {
            //全部锁定后,按选择激活
            this.SetMlineComponetDisable();

            if (this.cmbMlineFirst.SelectedValue.ToString().Length > 5)
            {
                return;                                                         //处理冲突,启动时会激活该事件报错
            }
            //设置下级下拉框的级联变化
            LevelSearchor.searchAndSetLevel2(this.cmbMlineSecond, "8", this.cmbMlineFirst.SelectedValue.ToString());

            //根据选择,决定激活哪些控件
            this.SetMlineEnableComponent();

            //实时生成编码
            this.GenerateMlineCode();
        }
示例#7
0
        private void cmbProductionSecond_SelectedIndexChanged(object sender, EventArgs e)
        {
            //全部锁定后,按选择激活
            this.SetProductionComponetDisable();

            if (this.cmbProductionSecond.SelectedValue.ToString().Length > 5)
            {
                return;                                                               //处理冲突,启动时会激活该事件报错
            }
            //级联变化
            LevelSearchor.searchAndSetLevel3(this.cmbProductionThird,
                                             "9",
                                             this.cmbProductionFirst.SelectedValue.ToString(),
                                             this.cmbProductionSecond.SelectedValue.ToString());

            //根据选择,决定激活哪些控件
            this.SetProductionEnableComponent();

            //实时生成编码
            this.GenerateProductionCode();
        }
示例#8
0
 private void LoadDataTocmbProductionFirst()
 {
     LevelSearchor.searchAndSetLevel1(this.cmbProductionFirst, "9");
 }
示例#9
0
 private void btnCodeReverse_Click(object sender, EventArgs e)
 {
     string[] codeArr = this.txtCodeReverse.Text.Split('.');
     lblCodeInfo.Text = LevelSearchor.GetFields1(codeArr[0]);
     lblCodeInfo.Text = lblCodeInfo.Text + LevelSearchor.GetFields2(codeArr[0], codeArr[1]);
 }
示例#10
0
 private void LoadDataTocmbContractFirst()
 {
     LevelSearchor.searchAndSetLevel1(this.cmbContractFirst, "7");
 }
示例#11
0
 private void LoadDataTocmbMlineFirst()
 {
     LevelSearchor.searchAndSetLevel1(this.cmbMlineFirst, "8");
 }
示例#12
0
 private void LoadDataTocmbAssistantFirst()
 {
     LevelSearchor.searchAndSetLevel1(this.cmbAssistantFirst, "6");
 }
示例#13
0
 private void LoadDataTocmbMetalFirst()
 {
     LevelSearchor.searchAndSetLevel1(this.cmbMetalFirst, "5");
 }
示例#14
0
 private void LoadDataTocmbElecFirst()
 {
     LevelSearchor.searchAndSetLevel1(this.cmbElecFirst, "3");
 }
示例#15
0
 private void LoadDataTocmbStdFirst()
 {
     LevelSearchor.searchAndSetLevel1(this.cmbStdFirst, "2");
 }
示例#16
0
 private void LoadDataToCmbRawFirst()
 {
     LevelSearchor.searchAndSetLevel1(this.cmbRawFirst, "1");
 }