0

I declared a new FormControl like this :

senderCity = new FormControl("", [Validators.required ]);

In future I add some value like :

    if(legBet){
        let splited = legBet.value.split(',');
        this[errorLable].setValidators([ Validators.minLength(splited[0]), Validators.maxLength(splited[1]) ]);
  }

But seems not works expected. when max, min length not throws error. is it correct way to add or some wrong here?

any one help me?

user2024080
  • 1
  • 14
  • 56
  • 96

0 Answers0