예제 #1
0
        private void IsReg_Click(object sender, RoutedEventArgs e)
        {
            AuthorizationUsers authorizationUsers = new AuthorizationUsers();

            authorizationUsers.Show();
            this.Hide();
        }
예제 #2
0
        private void ExitBttn_Click(object sender, RoutedEventArgs e)
        {
            saveData.ReadXml();
            saveData.Fields.AutoAuthorization = false;
            saveData.WriteXml();
            AuthorizationUsers windowAuthorization = new AuthorizationUsers();

            windowAuthorization.Show();
            this.Hide();
        }
예제 #3
0
        private void RegistrationServer()
        {
            string isSaveIP = "0";

            if (!IsValid(Login.Text, 6, 30, "Логин") || !IsValid(Password.Password, 8, 30, "Пароль"))
            {
                return;
            }
            if (!isLicenseChek.IsChecked.Value)
            {
                Message("INFO", "Вы не согласились с лицензиями"); return;
            }

            if (IsSaveIp.IsChecked.Value)
            {
                isSaveIP = "1";
            }
            else
            {
                isSaveIP = "0";
            }

            string[] NameComand = { "login", "password", "IsSaveIP", "email", "phone" };
            string[] SendComand = { Login.Text, Password.Password, isSaveIP, email.Text, phone.Text };

            string result = Send("MainRegistration", NameComand, SendComand, Config.url[0]);

            if (string.Compare(result, "64677") == 0)
            {
                WriteSetting();
                AuthorizationUsers authorizationUsers = new AuthorizationUsers();
                authorizationUsers.Show();
                this.Hide();
            }
            else
            {
                Message("REG INFO", result);
            }
        }