Monday, 11 October 2021

ngmodel error

 when ngmodel is declared inside the form tags then get error cant use then that case 

use this tag its work absolutly fine 

 <mat-cell *matCellDef="let element">       <mat-checkbox [(ngModel)]="element.selected" [ngModelOptions]="{standalone: true}"> </mat-checkbox>
  </mat-cell>
ngmodeloption true


error:ngModel cannot be used to register form controls with a parent formGroup directive. Try using formGroup's partner directive "formControlName"

No comments:

Post a Comment

7 Common mistakes in Dot Net — You can avoid

  There are many common mistakes made during .NET (ASP.NET, .NET Core) development, which affect performance, security, and code… Code Crack...