private void button3_Click_1(object sender, EventArgs e) { var userName = this.textBox1.Text.ToString(); var passWord = this.textBox2.Text.ToString(); Connection connection=new Connection(); var number= connection.Login(userName, passWord); if (number > 0) { Number = number; } else { Number = 0; GreatForm("密码或者用户名错误,或者次数已经用完。"); return; } UserName = userName; this.labelName.Text = userName; this.labelNumber.Text = (Number + 3).ToString(); }
private void ThreadFuntion() { //Number = QueryNunber("Administrator"); test_3 Connection connection =new Connection(); Number = connection.QueryNunber("test_3"); if (Number == 0) { this.webBrowser1.Navigate("http://www.tianmaoyu.com"); } this.labelNumber.Text = (Number + 3).ToString(); }
public void TheadUpdata(object o) { string s = o as string; //UpdateDatabase(s); Connection connection = new Connection(); connection.UpdateDatabase(s); }