//修改分组名称 private void ChangName_Click(object sender, EventArgs e) { AddCatsFrm addfrm = new AddCatsFrm(loginfrm, this); //判断是哪个按钮打开窗口 addfrm.Btn(false); DialogResult myRe = addfrm.ShowDialog(); if (myRe == DialogResult.OK) { this.timer1.Enabled = true; } }
//添加分组方法 public void addCats() { AddCatsFrm addfrm = new AddCatsFrm(loginfrm, this); //判断是哪个按钮打开窗口 addfrm.Btn(true); DialogResult myRe = addfrm.ShowDialog(); if (myRe == DialogResult.OK) { this.timer1.Enabled = true; } }