public FormTimeSetting() { InitializeComponent(); currentFont = new Font("微软雅黑", 14F, FontStyle.Regular); dateImage = new SimpleImagesContaner(); dateImage.BackImg = dateImage.CheckedBackImg = dateImage.ImgDisable = AdvaMACSystemRes.Dgn_disable; inputImage = new SimpleImagesContaner(); inputImage.BackImg = inputImage.CheckedBackImg = inputImage.ImgDisable = AdvaMACSystemRes.Input40x40; buttonImage = new ImagesContaner(); buttonImage.DNImg = AdvaMACSystemRes.Dgn_down; buttonImage.UPImg = AdvaMACSystemRes.Dgn_up; buttonImage.UPImgDisaable = buttonImage.DNImgDisable = AdvaMACSystemRes.Dgn_disable; buttonList = new List <ImageButton>(); ibPressure = new ImageButton(); buttonList.Add(ibPressure); ibPosition = new ImageButton(); buttonList.Add(ibPosition); ibBack = new ImageButton(); buttonList.Add(ibBack); ibEnter = new ImageButton(); buttonList.Add(ibEnter); lbTimeSetting = new Label(); inputLabelList = new List <ImageLabel>(); ilStartHour = new ImageLabel(); ilStartHour.Click += new EventHandler(ilStartHour_Click); inputLabelList.Add(ilStartHour); ilStartMinute = new ImageLabel(); ilStartMinute.Click += new EventHandler(ilStartMinute_Click); inputLabelList.Add(ilStartMinute); ilHourSpan = new ImageLabel(); inputLabelList.Add(ilHourSpan); ilHourSpan.Click += new EventHandler(ilHourSpan_Click); ilMinuteSpan = new ImageLabel(); inputLabelList.Add(ilMinuteSpan); ilMinuteSpan.Click += new EventHandler(ilMinuteSpan_Click); for (int i = 0; i < inputLabelList.Count; i++) { inputLabelList[i].Size = new Size(40, 40); inputLabelList[i].Location = new Point(LBTimeMarginLeft + i * (40 + LBTimeSpacingX), LBTimeMarginTop); inputLabelList[i].Font = currentFont; inputLabelList[i].IMGContainer = inputImage; this.Controls.Add(inputLabelList[i]); } for (int k = 0; k < buttonList.Count; k++) { ImageButton button = buttonList[k]; button.Size = new Size(ButtonWidth, ButtonHeight); button.Location = new Point(ButtonMarginLeft + (k % 2) * (ButtonWidth + ButtonSpacingX), ButtonMarginTop + (k / 2) * (ButtonHeight + ButtonSpacingY)); button.Font = currentFont; button.IMGContainer = buttonImage; this.Controls.Add(button); } ibPressure.Text = "轴力记录"; ibPressure.Name = "Pressure"; ibPressure.Toggle = true; ibPressure.CheckedChanged += new EventHandler(dataTypeChanged); ibPosition.Text = "位移记录"; ibPosition.Name = "Position"; ibPosition.Toggle = true; ibPosition.CheckedChanged += new EventHandler(dataTypeChanged); ibBack.Text = "返回"; ibBack.Click += new EventHandler(ibBack_Click); ibEnter.Text = "确认"; ibEnter.Click += new EventHandler(ibEnter_Click); foreach (Control c in this.Controls) { if (!(c is MonthCalendar)) { c.Font = currentFont; } } //foreach (Control c in this.Controls) //{ // if (c is MonthCalendar) // c.Font = new Font("微软雅黑", 10F, FontStyle.Regular); // else // c.Font = currentFont; //} //monthCalendar1.Location = new Point((this.Width - monthCalendar1.Width) / 2, monthCalendar1.Top); }
public PageViewHistory() { InitializeComponent(); timeSetting = new FormTimeSetting(); this.ForeColor = Color.Black; sf = new StringFormat(); sf.Alignment = StringAlignment.Center; sf.LineAlignment = StringAlignment.Center; chartFont = new Font("微软雅黑", 9F, FontStyle.Regular); currentFont = new Font("微软雅黑", 14F, FontStyle.Regular); buttonImage = new ImagesContaner(); buttonImage.DNImg = AdvaMACSystemRes.Dgn_down; buttonImage.UPImg = AdvaMACSystemRes.Dgn_up; buttonImage.UPImgDisaable = buttonImage.DNImgDisable = AdvaMACSystemRes.Dgn_disable; ibBack = new ImageButton(); ibBack.Size = new Size(ButtonWidth, ButtonHeight); ibBack.Location = new Point(800, 600); ibBack.IMGContainer = buttonImage; ibBack.Font = currentFont; ibBack.Text = "返回"; ibBack.Click += new EventHandler(ibBack_Click); this.Controls.Add(ibBack); cylinderList = new List <ImageButton>(); for (int i = 0; i < 8; i++) { ImageButton cylinder = new ImageButton(); cylinderList.Add(cylinder); cylinder.Size = new Size(CylinderWidth, CylinderHeight); cylinder.Location = new Point(CylinderMarginLeft, CylinderMarginTop + i * (CylinderHeight + CylinderSpacingY)); cylinder.IMGContainer = buttonImage; cylinder.Font = currentFont; cylinder.ForeColor = textColor; cylinder.Tag = i; cylinder.Text = (i + 1).ToString() + "#油缸"; cylinder.Toggle = true; cylinder.Click += new EventHandler(cylinder_Click); this.Controls.Add(cylinder); } dateImage = new SimpleImagesContaner(); dateImage.BackImg = dateImage.CheckedBackImg = dateImage.ImgDisable = AdvaMACSystemRes.Dgn_disable; inputImage = new SimpleImagesContaner(); inputImage.BackImg = inputImage.CheckedBackImg = inputImage.ImgDisable = AdvaMACSystemRes.Input40x40; imageLabel_title = new ComCtrls.ImageLabel(); pBox = new PictureBox(); pbDataTable = new PictureBox(); lbPumpName = new Label(); ilDate = new ImageLabel(); ibPrevDay = new ImageButton(); ibNextDay = new ImageButton(); ilPumpIndex = new ImageLabel(); ilCurrentPage = new ImageLabel(); lbPage = new Label(); prevPage = new ImageButton(); nextPage = new ImageButton(); this.SuspendLayout(); prevPage.Size = new Size(40, 40); prevPage.Location = new Point(BmpLeft, 562); prevPage.Font = currentFont; prevPage.UPImg = prevPage.UPImgDisable = AdvaMACSystemRes.leftup; prevPage.DNImg = prevPage.DNImgDisable = AdvaMACSystemRes.leftdown; prevPage.Click += new EventHandler(prevPage_Click); this.Controls.Add(prevPage); nextPage.Size = new Size(40, 40); nextPage.Location = new Point(BmpLeft + 350, 562); nextPage.Font = currentFont; nextPage.UPImg = nextPage.UPImgDisable = AdvaMACSystemRes.rightup; nextPage.DNImg = nextPage.DNImgDisable = AdvaMACSystemRes.rightdown; nextPage.Click += new EventHandler(nextPage_Click); this.Controls.Add(nextPage); ibPrevDay.Size = new Size(100, 40); ibPrevDay.Location = new Point(CylinderMarginLeft, CylinderMarginTop + 9 * (CylinderHeight + CylinderSpacingY)); ibPrevDay.Font = currentFont; ibPrevDay.Text = "前一天"; ibPrevDay.UPImg = ibPrevDay.UPImgDisable = AdvaMACSystemRes.half_disable; ibPrevDay.DNImg = ibPrevDay.DNImgDisable = AdvaMACSystemRes.half_disable; ibPrevDay.Click += new EventHandler(ibPrevDay_Click); this.Controls.Add(ibPrevDay); ibNextDay.Size = new Size(100, 40); ibNextDay.Location = new Point(CylinderMarginLeft + 110, CylinderMarginTop + 9 * (CylinderHeight + CylinderSpacingY)); ibNextDay.Font = currentFont; ibNextDay.Text = "后一天"; ibNextDay.UPImg = ibNextDay.UPImgDisable = AdvaMACSystemRes.half_disable; ibNextDay.DNImg = ibNextDay.DNImgDisable = AdvaMACSystemRes.half_disable; ibNextDay.Click += new EventHandler(ibNextDay_Click); this.Controls.Add(ibNextDay); this.imageLabel_title.BackColor = System.Drawing.Color.Silver; this.imageLabel_title.Checked = false; this.imageLabel_title.Dock = System.Windows.Forms.DockStyle.Top; this.imageLabel_title.Font = new System.Drawing.Font("Arial", 20F, System.Drawing.FontStyle.Bold); this.imageLabel_title.Location = new System.Drawing.Point(0, 0); this.imageLabel_title.Name = "imageLabel_title"; this.imageLabel_title.Size = new System.Drawing.Size(1024, 57); this.imageLabel_title.TabIndex = 0; this.imageLabel_title.Text = "历史记录"; this.imageLabel_title.TransParent = false; this.Controls.Add(this.imageLabel_title); pBox.Size = new Size(BmpWidth, BmpHeight); pBox.Location = new Point(BmpLeft, BmpTop); pBox.Visible = true; this.Controls.Add(pBox); pbDataTable.Size = new Size(CellWidth * Columns + 1, CellHeight * Lines + 1); pbDataTable.Location = new Point(BmpLeft, TableMarginTop); pbDataTable.Visible = true; this.Controls.Add(pbDataTable); lbPumpName.Size = new Size(100, 40); lbPumpName.Location = new Point(CylinderMarginLeft + 100, CylinderMarginTop - CylinderHeight - CylinderSpacingY + 10); lbPumpName.Font = currentFont; lbPumpName.Text = "号泵站"; this.Controls.Add(lbPumpName); ilDate.Size = new Size(CylinderWidth, CylinderHeight); ilDate.Location = new Point(CylinderMarginLeft, CylinderMarginTop + 8 * (CylinderHeight + CylinderSpacingY)); ilDate.Font = currentFont; ilDate.IMGContainer = dateImage; ilDate.Click += new EventHandler(ilDate_Click); this.Controls.Add(ilDate); ilCurrentPage.Size = new Size(80, 40); ilCurrentPage.Location = new Point(BmpLeft + 70, 562); ilCurrentPage.Font = currentFont; ilCurrentPage.BackImg = AdvaMACSystemRes.Input80x40; ilCurrentPage.Click += new EventHandler(ilCurrentPage_Click); this.Controls.Add(ilCurrentPage); ilPumpIndex.Size = new Size(40, 40); ilPumpIndex.Font = currentFont; ilPumpIndex.IMGContainer = inputImage; ilPumpIndex.Location = new Point(CylinderMarginLeft + 50, CylinderMarginTop - CylinderHeight - CylinderSpacingY); ilPumpIndex.Click += new EventHandler(ilPumpIndex_Click); this.Controls.Add(ilPumpIndex); lbPage.Size = new Size(300, 40); lbPage.Location = new Point(BmpLeft + 45, 572); lbPage.Font = currentFont; this.Controls.Add(lbPage); this.ResumeLayout(false); }
public PageViewDiagnose() { InitializeComponent(); _candatapool = DataPool.CDataPool.GetDataPoolObject(); this.ForeColor = Color.Black; pumpImgLabelList = new List <CParaLabel>(); pumpTitleList = new List <ImageLabel>(); cylinderIOList = new List <ImageLabel>(); cylinderParaList = new List <CParaLabel>(); buttonList = new List <ImageButton>(); pumpNameImage = new SimpleImagesContaner(); pumpNameImage.BackImg = pumpNameImage.CheckedBackImg = pumpNameImage.ImgDisable = AdvaMACSystemRes.IO; pumpParaImage = new SimpleImagesContaner(); pumpParaImage.BackImg = pumpParaImage.CheckedBackImg = pumpParaImage.ImgDisable = AdvaMACSystemRes.IOlabel; buttonImage = new ImagesContaner(); buttonImage.DNImg = AdvaMACSystemRes.Dgn_down; buttonImage.UPImg = AdvaMACSystemRes.Dgn_up; buttonImage.UPImgDisaable = buttonImage.DNImgDisable = AdvaMACSystemRes.Dgn_disable; cylinderImage = new SimpleImagesContaner(); cylinderImage.BackImg = AdvaMACSystemRes.IOred; cylinderImage.ImgDisable = AdvaMACSystemRes.IOred; cylinderImage.CheckedBackImg = AdvaMACSystemRes.IOblack; currentFont = new Font("微软雅黑", 14F, FontStyle.Regular); //new pump names for (int i = 0; i < 4; i++) { ImageLabel pumpName = new ImageLabel(); pumpTitleList.Add(pumpName); } //new pump paras for (int i = 0; i < 12; i++) { CParaLabel pumpPara = new CParaLabel(); pumpImgLabelList.Add(pumpPara); } //new cylinders for (int i = 0; i < 32; i++) { ImageLabel cylinder = new ImageLabel(); cylinderIOList.Add(cylinder); } for (int i = 0; i < 32; i++) { CParaLabel cylinderPara = new CParaLabel(); cylinderParaList.Add(cylinderPara); } for (int i = 0; i < 4; i++) { ImageButton button = new ImageButton(); buttonList.Add(button); } exitButton = new ImageButton(); panelIO = new Panel(); panelPara = new Panel(); this.imageLabel_title = new ComCtrls.ImageLabel(); this.SuspendLayout(); this.panelIO.SuspendLayout(); this.panelPara.SuspendLayout(); this.imageLabel_title.BackColor = System.Drawing.Color.Silver; this.imageLabel_title.Checked = false; this.imageLabel_title.Dock = System.Windows.Forms.DockStyle.Top; this.imageLabel_title.Font = new System.Drawing.Font("Arial", 20F, System.Drawing.FontStyle.Bold); this.imageLabel_title.Layout = ComCtrls.KTLayout.GlyphTop; this.imageLabel_title.Location = new System.Drawing.Point(0, 0); this.imageLabel_title.Name = "imageLabel_title"; this.imageLabel_title.Size = new System.Drawing.Size(1024, 57); this.imageLabel_title.TabIndex = 0; this.imageLabel_title.Text = "I/O诊断"; this.imageLabel_title.TextX = -1F; this.imageLabel_title.TextY = -1F; this.imageLabel_title.TransParent = false; this.Controls.Add(this.imageLabel_title); panelIO.Size = new Size(1024, 8 * (IOHeight + IOSpacingY)); panelIO.Location = new Point(IOMarginLeft, 4 * (IOHeight + IOSpacingY) + IOMarginTop); panelIO.Visible = false; this.Controls.Add(panelIO); panelPara.Size = new Size(1024, 8 * (IOHeight + IOSpacingY)); panelPara.Location = new Point(IOMarginLeft, 4 * (IOHeight + IOSpacingY) + IOMarginTop); panelPara.Visible = false; this.Controls.Add(panelPara); for (int i = 0; i < 4; i++) { ImageLabel pumpName = pumpTitleList[i]; pumpName.Size = new Size(IOWidth, IOHeight); pumpName.Location = new Point(IOMarginLeft + i * (IOWidth + IOSpacingX), IOMarginTop); pumpName.Font = currentFont; pumpName.TransParent = true; pumpName.ForeColor = textColor; pumpName.IMGContainer = pumpNameImage; this.Controls.Add(pumpName); } for (int i = 0; i < 12; i++) { CParaLabel pumpPara = pumpImgLabelList[i]; pumpPara.Size = new Size(IOWidth, IOHeight); pumpPara.Location = new Point(IOMarginLeft + (i / 3) * (IOWidth + IOSpacingX), IOMarginTop + (i % 3 + 1) * (IOHeight + IOSpacingY)); pumpPara.Font = currentFont; pumpPara.ForeColor = textColor; pumpPara.TransParent = true; pumpPara.TextX = TextMarginLeft; pumpPara.TextY = TextMarginTop; pumpPara.IMGContainer = pumpParaImage; this.Controls.Add(pumpPara); } for (int i = 0; i < 32; i++) { ImageLabel cylinder = cylinderIOList[i]; cylinder.Size = new Size(IOWidth, IOHeight); cylinder.Location = new Point((i / 8) * (IOWidth + IOSpacingX), (i % 8) * (IOHeight + IOSpacingY)); cylinder.IMGContainer = cylinderImage; cylinder.Font = currentFont; cylinder.ForeColor = textColor; cylinder.TransParent = true; cylinder.TextX = TextMarginLeft; cylinder.TextY = TextMarginTop; this.panelIO.Controls.Add(cylinder); } for (int i = 0; i < 32; i++) { CParaLabel cylinderPara = cylinderParaList[i]; cylinderPara.Size = new Size(IOWidth, IOHeight); cylinderPara.Location = new Point((i / 8) * (IOWidth + IOSpacingX), (i % 8) * (IOHeight + IOSpacingY)); cylinderPara.IMGContainer = pumpParaImage; cylinderPara.Font = currentFont; cylinderPara.ForeColor = textColor; cylinderPara.TransParent = true; cylinderPara.TextX = TextMarginLeft; cylinderPara.TextY = TextMarginTop; this.panelPara.Controls.Add(cylinderPara); } for (int i = 0; i < 4; i++) { ImageButton button = buttonList[i]; button.Size = new Size(ButtonWidth, ButtonHeight); button.Location = new Point(IOMarginLeft + i * (ButtonWidth + ButtonSpacingX), ButtonMarginTop); button.IMGContainer = buttonImage; button.Click += new EventHandler(diagnoseItemButton_Click); button.Toggle = true; button.Font = currentFont; button.ForeColor = textColor; button.Tag = i;//diagnoseItem_Tag this.Controls.Add(button); } buttonList[0].Text = "近端锁定螺母限位"; buttonList[1].Text = "远端锁定螺母限位"; buttonList[2].Text = "油缸运行状态"; buttonList[3].Text = "油缸机械锁状态"; exitButton.Size = new Size(ButtonWidth, ButtonHeight); exitButton.Location = new Point(IOMarginLeft + 3 * (ButtonWidth + ButtonSpacingX), ButtonMarginTop + (ButtonHeight + ButtonSpacingY)); exitButton.IMGContainer = buttonImage; exitButton.Font = currentFont; exitButton.ForeColor = System.Drawing.Color.Black; exitButton.Text = "返回"; exitButton.CheckedChanged += new EventHandler(exitButton_CheckedChanged); this.Controls.Add(exitButton); this.panelPara.ResumeLayout(false); this.panelIO.ResumeLayout(false); this.ResumeLayout(false); }
public PageViewMAC() { InitializeComponent(); this.ForeColor = Color.Black; currentFont = new System.Drawing.Font("微软雅黑", 20F, System.Drawing.FontStyle.Regular); _candatapool = CDataPool.GetDataPoolObject(); //pump美化 pumpIcon = AdvaMACSystemRes.pump; pumpImages = new ImagesContaner(); pumpImages.DNImg = AdvaMACSystemRes.pumpborder_checked; pumpImages.UPImg = AdvaMACSystemRes.pumpborder; pumpImages.DNImgDisable = AdvaMACSystemRes.pumpborder_disable; pumpImages.UPImgDisaable = AdvaMACSystemRes.pumpborder_disable; //button美化 buttonImages = new ImagesContaner(); buttonImages.DNImg = AdvaMACSystemRes.MAC_down; buttonImages.UPImg = AdvaMACSystemRes.MAC_up; buttonImages.DNImgDisable = AdvaMACSystemRes.MAC_disable; buttonImages.UPImgDisaable = AdvaMACSystemRes.MAC_disable; //cylinder美化 progressBarImages = new CProgressBarImagesContainer(); progressBarImages.BgImage = AdvaMACSystemRes.graybar; progressBarImages.FrontImage = AdvaMACSystemRes.greenbar; progressBarImages.FrontImage_Unpass = AdvaMACSystemRes.redbar; progressBarImages.WarningImage = AdvaMACSystemRes.yellowbar; progressBarImages.SettingImage = AdvaMACSystemRes.bluebar; //new pumps pumpList = new List <CPumpButton>(); for (int j = 0; j < pumpNumber; j++) { CPumpButton pumpBlock = new CPumpButton(); pumpList.Add(pumpBlock); } //new cylinders cylinderList = new List <CylinderCellBlock>(); for (int i = 0; i < cylinderNumber; i++) { CylinderCellBlock cylinder = new CylinderCellBlock(); cylinderList.Add(cylinder); } //new buttons controlModeButton = new ImageButton(); //controlButtonList = new List<ImageButton>(); //autoModeButton = new ImageButton(); //controlButtonList.Add(autoModeButton); //manualModeButton = new ImageButton(); //controlButtonList.Add(manualModeButton); stateButtonList = new List <ImageButton>(); PumpSettingButton = new ImageButton(); //stateButtonList.Add(PumpSettingButton); PumpInstallButton = new ImageButton(); stateButtonList.Add(PumpInstallButton); cylinderExtendButton = new ImageButton(); stateButtonList.Add(cylinderExtendButton); //cylinderStopButton = new ImageButton(); //stateButtonList.Add(cylinderStopButton); cylinderRetractButton = new ImageButton(); stateButtonList.Add(cylinderRetractButton); this.SuspendLayout(); //pumps for (int j = 0; j < pumpNumber; j++) { CPumpButton pumpBlock = pumpList[j]; pumpBlock.Size = new Size(PumpWidth, PumpHeight); pumpBlock.Location = new Point(PumpMarginLeft, PumpMarginTop + j * (PumpHeight + PumpSpacingY)); pumpBlock.Toggle = true; pumpBlock.PumpIndex = j; pumpBlock.IMGContainer = pumpImages; pumpBlock.TransParent = true; pumpBlock.Icon = pumpIcon; pumpBlock.Click += new EventHandler(pumpBlock_Click); this.Controls.Add(pumpBlock); } //cylinders for (int i = 0; i < cylinderNumber; i++) { CylinderCellBlock cylinder = cylinderList[i]; cylinder.Size = new Size(CBWidth, CBHeight); cylinder.Location = new Point(CBMarginLeft + (i % 2) * (CBWidth + CBSpacingX), CBMarginTop + (i / 2) * (CBHeight + CBSpacingY)); cylinder.OnCylinderClicked += new OnCylinderClickHandler(cylinder_OnCylinderClicked); cylinder.IMGContainer = progressBarImages; //cylinder.Font = currentFont; this.Controls.Add(cylinder); } //buttons controlModeButton.Size = new Size(ButtonWidth, ButtonHeight); controlModeButton.Location = new Point(ButtonMarginLeft, ButtonMarginTop); controlModeButton.Font = currentFont; controlModeButton.IMGContainer = buttonImages; controlModeButton.Checked = false; controlModeButton.Toggle = false; //controlModeButton.CheckedChanged += new EventHandler(controlModeButton_CheckedChanged); //controlModeButton.MouseUp += new MouseEventHandler(controlModeButton_MouseUp); //controlModeButton.Click += new EventHandler(controlModeButton_Click); controlModeButton.Text = "自动模式"; this.Controls.Add(controlModeButton); //for (int k = 0; k < controlButtonList.Count; k++) //{ // ImageButton button = controlButtonList[k]; // button.Size = new Size(ButtonWidth, ButtonHeight); // button.Location = new Point(ButtonMarginLeft, ButtonMarginTop + k * (ButtonHeight + ButtonSpacingY)); // button.Font = currentFont; // button.IMGContainer = buttonImages; // button.Toggle = true; // button.Click += new EventHandler(controlModeButton_Click); // this.Controls.Add(button); //} //autoModeButton.Name = "auto"; //manualModeButton.Name = "manual"; //autoModeButton.Text = "自动模式"; //manualModeButton.Text = "手动模式"; for (int k = 0; k < stateButtonList.Count; k++) { ImageButton button = stateButtonList[k]; button.Size = new Size(ButtonWidth, ButtonHeight); button.Location = new Point(ButtonMarginLeft + (k + 1) * (ButtonWidth + ButtonSpacingX), ButtonMarginTop); button.Font = currentFont; button.IMGContainer = buttonImages; button.Toggle = false; this.Controls.Add(button); } cylinderExtendButton.Text = "油缸伸出"; //cylinderExtendButton.Click += new EventHandler(cylinderExtendButton_Click); cylinderExtendButton.MouseDown += new MouseEventHandler(cylinderExtendButton_MouseDown); cylinderExtendButton.MouseUp += new MouseEventHandler(cylinderExtendButton_MouseUp); //cylinderStopButton.Text = "油缸停止"; //cylinderStopButton.Click += new EventHandler(cylinderStopButton_Click); cylinderRetractButton.Text = "油缸缩回"; //cylinderRetractButton.Click += new EventHandler(cylinderRetractButton_Click); cylinderRetractButton.MouseDown += new MouseEventHandler(cylinderRetractButton_MouseDown); cylinderRetractButton.MouseUp += new MouseEventHandler(cylinderRetractButton_MouseUp); cylinderExtendButton.Enabled = false; //cylinderStopButton.Enabled = false; cylinderRetractButton.Enabled = false; PumpInstallButton.Text = "启动泵站"; PumpInstallButton.Click += new EventHandler(PumpInstallButton_Click); //PumpInstallButton.MouseDown += new MouseEventHandler(); //PumpInstallButton.MouseUp += new MouseEventHandler(); PumpInstallButton.Enabled = false; PumpSettingButton.Text = "轴力设定"; PumpSettingButton.Click += new EventHandler(PumpSettingButton_Click); //PumpSettingButton.MouseDown += new MouseEventHandler(); //PumpSettingButton.MouseUp += new MouseEventHandler(); PumpSettingButton.Enabled = false; this.ResumeLayout(false); }