void Reset() { rnd = new RandomNumberGenerator(); Txt_Min.Text = rnd.Min.ToString(); Txt_Max.Text = rnd.Max.ToString(); Txt_Result.Clear(); }
private void Btn_0_Click(object sender, EventArgs e) { if (mate) { Txt_Result.Clear(); mate = false; } Txt_Result.Text += "0"; }
private void Btn_Calc_Click(object sender, EventArgs e) { //判断输入字符是否为空 if (Txt_Result.Text == string.Empty) { return; } oper.NumberB = Convert.ToInt32(Txt_Result.Text); Txt_Calc.Text += Txt_Result.Text + "="; Txt_Result.Clear(); ans = oper.GetResult(); Txt_Result.Text = ans.ToString(); mate = true; }
//读取上个计算结果值 private void Btn_Ans_Click(object sender, EventArgs e) { Txt_Result.Clear(); Txt_Result.Text = ans.ToString(); }