private void pictureBox4_Click(object sender, EventArgs e) { if (skinTextBox1.Text != "" && skinTextBox2.Text != "" && skinTextBox3.Text != "") { if (IsNum(skinTextBox3.Text)) //检测端口的数字符合度 { pictureBox4.Image = Window_Client.Properties.Resources.loading; String Ret = CheckUser("UserLoginCheck"); /* * Ret :no yes Link Error */ pictureBox4.Image = Window_Client.Properties.Resources.login_check; if (Ret.Trim().Equals("Link Error")) { Info_MessageBox("登录信息提示", "无法连接验证服务器!"); } else if (Ret.Trim().Equals("no")) { Info_MessageBox("登录信息提示", "用户登录信息错误!"); } else { //登录成功 this.Hide(); Main_Panel mainControlPanel = new Main_Panel(); mainControlPanel.username = skinTextBox1.Text.Trim(); //传递用户名数据 mainControlPanel.password = skinTextBox2.Text.Trim(); //传递密码数据 mainControlPanel.Show(); } } else { Info_MessageBox("登录信息提示", "请正确填写服务器端口!"); } } else { Info_MessageBox("登录信息提示", "请填写完整的登录信息!"); } }
private void pictureBox4_Click(object sender, EventArgs e) { if (skinTextBox1.Text != "" && skinTextBox2.Text != "" && skinTextBox3.Text != "") { if (IsNum(skinTextBox3.Text)) //检测端口的数字符合度 { pictureBox4.Image = Window_Client.Properties.Resources.loading; String Ret=CheckUser("UserLoginCheck"); /* Ret :no yes Link Error */ pictureBox4.Image = Window_Client.Properties.Resources.login_check; if (Ret.Trim().Equals("Link Error")) Info_MessageBox("登录信息提示", "无法连接验证服务器!"); else if (Ret.Trim().Equals("no")) Info_MessageBox("登录信息提示", "用户登录信息错误!"); else { //登录成功 this.Hide(); Main_Panel mainControlPanel = new Main_Panel(); mainControlPanel.username = skinTextBox1.Text.Trim(); //传递用户名数据 mainControlPanel.password = skinTextBox2.Text.Trim(); //传递密码数据 mainControlPanel.Show(); } } else { Info_MessageBox("登录信息提示", "请正确填写服务器端口!"); } } else { Info_MessageBox("登录信息提示", "请填写完整的登录信息!"); } }