0

I get this message:

Error: No value accessor for form control with unspecified name attribute

HTML is:

<div>
  <input #input type="text" name="input" />
  <div range [formControl]="input" [classCss]="'close_btn'">Select</div>
</div>

1 Answers1

1

If you want the value from input filed use it like this : -

<input name="name" ngModel id="someId" placeholder="Enter some data" type="text" class="form-control" required>

OR

<input name="name" [(ngModel)] = "name" id="someId" placeholder="Enter some data" type="text" class="form-control" required>
Aniket
  • 391
  • 5
  • 13