private void btn_Click(object sender, EventArgs e) { Module api = new Module(); api = new Module(); F3 = new FORM_03(); F1 = new ID_Maker(); string Correctid = api.getIdPass("http://192.168.3.15:5000/SI_select_Pos_Id"); string Correctpw = api.getIdPass("http://192.168.3.15:5000/SI_select_Pos_Pass"); if (텍스트박스1.Text == Correctid && 텍스트박스2.Text == Correctpw) { F3.Show(); Dispose(false); } if (텍스트박스1.Text.Length == 0 || 텍스트박스2.Text.Length == 0) { MessageBox.Show("입력을 받지 않았습니다. 다시 입력해주시기 바랍니다."); } else if (텍스트박스1.Text != Correctid) { MessageBox.Show("아이디를 잘못 입력하셨습니다."); } else if (텍스트박스1.Text == Correctid && 텍스트박스2.Text != Correctpw) { MessageBox.Show("비밀번호를 잘못 입력하셨습니다."); } }
//DB의 No = 1이 없으면 가입하고 가입되었습니다. 넣고 DB의 NO = 2 이상은 MessageBox로 이미 회원가입을 하셨습니다. 라는 메세지박스 출력할것. private void btn_Click(object sender, EventArgs e) { F1 = new ID_Maker(); api = new Module(); string Correctid = api.getIdPass("http://192.168.3.15:5000/sp_Pos_Count"); if (Correctid != "[[\"0\"]]") { MessageBox.Show("아이디가 존재 합니다."); } else { if (네임택박.Text.Length == 0 || 포지션택박.Text.Length == 0 || 패스워드택박.Text.Length == 0 || 시리얼택박.Text.Length == 0) { MessageBox.Show("값을 입력 받지 않았습니다.\n 확인 후 입력해주세요."); } else { if (시리얼택박.Text != "GUDI") { MessageBox.Show("시리얼 번호가 맞지 않습니다. 다시 입력해주시기 바랍니다."); } else { Hashtable ht = new Hashtable(); ht.Add("ps_Id", 네임택박.Text); ht.Add("ps_Rank", 포지션택박.Text); ht.Add("ps_passwd", 패스워드택박.Text); ht.Add("ps_code", 시리얼택박.Text); api.insert_Category("http://192.168.3.28:5000/SI_insert_Pos", ht); Close(); } } } }