title: How to manipulate (valid / invalid) form validation on form control based on condition in Angular 4
body: <p>I have a form where i can update Email and Password so i created FormControl using form Group as </p>
  
  <pre><code>this.user= new FormGroup({
              Email: new FormControl("", [
                  Validators.required,
                  Validators.pattern("^[A-Za-z0-9._%+-]+@[A-Za-z0-9.-]+\.[A-Za-z]{2,4}$"),
                  Validators.maxLength(60)
              ]),
              ConfirmEmail: new FormControl("", [
                  Validators.required,
                  Validators.pattern("^[A-Za-z0-9._%+-]+@[A-Za-z0-9.-]+\.[A-Za-z]{2,4}$"),
                  Validators.maxLength(60)
              ]),
              Password: new FormControl("", [
                  Validators.required,
                  Validators.pattern("^(?=.*[a-z])(?=.*[A-Z])(?=.*\\d)[a-zA-Z\\d]{8,}$"),
                  Validators.maxLength(60)
              ]),
              ConfirmPassword: new FormControl("", [
                  Validators.required,
                  Validators.pattern("^(?=.*[a-z])(?=.*[A-Z])(?=.*\\d)[a-zA-Z\\d]{8,}$"),
                  Validators.maxLength(60)
              ])
          });
  </code></pre>
  
  <p>But Email and ConfirmEmail Section is shown only if user wants to update eventhough it is hidden using *ngIf The Form is still invalid because of email and Confirm email can we dynamically remove and add form controls</p>