private void txtbPriceCost_TextChanged(object sender, EventArgs e)
 {
     if (!MyRegEx.Validate(txtbPriceCost.Text, MyRegEx.OnlyDigits) && txtbPriceCost.Text != string.Empty)
     {
         epManageServiceToCustomer.SetError(txtbPriceCost, "רק ספרות");
     }
     else
     {
         epManageServiceToCustomer.SetError(txtbPriceCost, string.Empty);
     }
 }
Exemplo n.º 2
0
 private void txtBoxPrivateName_TextChanged(object sender, EventArgs e)
 {
     if (!MyRegEx.Validate(txtBoxPrivateName.Text, MyRegEx.OnlyCharsSpacesAndApostropheDigitsHebrew))
     {
         errorProvider1.SetError(txtBoxPrivateName, "רק אותיות גרש ורווחים מותרים");
     }
     else
     {
         errorProvider1.SetError(txtBoxPrivateName, string.Empty);
         EnableAddUser();
     }
 }
 private void txtbPrice_TextChanged(object sender, EventArgs e)
 {
     if (!MyRegEx.Validate(txtbPrice.Text, MyRegEx.OnlyDigits))
     {
         epManageServiceToCustomer.SetError(txtbPrice, "רק ספרות");
         canAdd = false;
     }
     else
     {
         epManageServiceToCustomer.SetError(txtbPrice, string.Empty);
         canAdd = true;
     }
     EnableAdd();
 }
 private void txtbServiceName_TextChanged(object sender, EventArgs e)
 {
     if (!MyRegEx.Validate(txtbServiceName.Text, MyRegEx.OnlyCharsSpacesAndApostropheDigitsHebrew))
     {
         errorPServices.SetError(txtbServiceName, "רק אותיות גרש ורווחים מותרים");
         _canAdd = false;
     }
     else
     {
         errorPServices.SetError(txtbServiceName, string.Empty);
         _canAdd = true;
     }
     EnableAdd();
 }
 private void txtbTypePriority_TextChanged(object sender, EventArgs e)
 {
     if (!MyRegEx.Validate(txtbTypePriority.Text, MyRegEx.OnlyCharsSpacesAndApostropheDigitsHebrew))
     {
         errorpPriority.SetError(txtbTypePriority, "רק אותיות גרש ורווחים מותרים");
         canAdd = false;
     }
     else
     {
         errorpPriority.SetError(txtbTypePriority, string.Empty);
         canAdd = true;
     }
     EnableAdd();
 }
Exemplo n.º 6
0
 private void txtBoxUserName_TextChanged(object sender, EventArgs e)
 {
     if (!MyRegEx.Validate(txtBoxUserName.Text, MyRegEx.OnlyCharsSpacesAndApostropheNumbers))
     {
         errorProvider1.SetError(txtBoxUserName, "רק אותיות באנגלית");
         isHebraw = false;
     }
     else
     {
         errorProvider1.SetError(txtBoxUserName, string.Empty);
         isHebraw = true;
         EnableAddUser();
     }
 }
 private void EnableConnect()
 {
     MyRegEx.Validate(txtBoxUserName.Text, MyRegEx.OnlyCharsPattern);
     buttonConnect.Enabled = txtBoxUserName.Text.Trim() != string.Empty && txtBoxPassWord.Text.Trim() != string.Empty;
 }