Skip to content

Instantly share code, notes, and snippets.

@Char0394
Created June 1, 2020 22:20
Show Gist options
  • Save Char0394/99663cdc975753c8f276ac83e55d5a2a to your computer and use it in GitHub Desktop.
Save Char0394/99663cdc975753c8f276ac83e55d5a2a to your computer and use it in GitHub Desktop.
public class RegisterPageViewModel: INotifyPropertyChanged
{
...
bool AreFieldsValid()
{
bool isFirstNameValid = FirstName.Validate();
bool isLastNameValid = LastName.Validate();
bool isBirthDayValid = BirthDay.Validate();
bool isPhoneNumberValid = PhoneNumber.Validate();
bool isEmailValid = Email.Validate();
bool isPasswordValid = Password.Validate();
bool isTermsAndConditionValid = TermsAndCondition.Validate();
return isFirstNameValid && isLastNameValid && isBirthDayValid
&& isPhoneNumberValid && isEmailValid && isPasswordValid && isTermsAndConditionValid;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment