Questions tagged [form-control]

Form control is the main component of Windows Forms UI framework. Forms represent application UI windows and dialogs. Use this tag only if you have specific problems in relation with Form control.

Form control (System.Windows.Forms.Form class) represents UI windows in Windows Forms GUI framework.

This tag is expected to be used together with .

472 questions
229
votes
31 answers

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

Here is my Angular component: @Component( { selector: 'input-extra-field', template: `
Sue
  • 2,380
  • 2
  • 10
  • 11
151
votes
5 answers

What is the difference between formControlName and FormControl?

I'm using ReactiveFormsModule of Angular2 to create a component that contains a form. Here is my code: foo.component.ts: constructor(fb: FormBuilder) { this.myForm = fb.group({ 'fullname': ['', Validators.required], 'gender': [] …
149
votes
13 answers

No value accessor for form control

I'm using Angular2-rc5, and I'm currently getting an error on my login page. I'm trying to make a form but the console throws exceptions telling me that it can't find my formcontrolls even though I create it on init. Any idea why I'm getting this…
AJ_
  • 3,787
  • 10
  • 47
  • 82
141
votes
7 answers

addControl to FormGroup dynamically in Angular

How can I add a FormControl to a FormGroup dynamically in Angular? For example, I would like to add a mandatory control which name is "new" and its default value is ''.
joeSmith
  • 1,445
  • 2
  • 8
  • 7
118
votes
4 answers

What is the difference between "Form Controls" and "ActiveX Control" in Excel 2010?

Using Microsoft Excel 2010, I noticed two kind of controls that can be inserted into a document: Form Controls and ActiveX Controls. What is the difference between them?
Rubens Mariuzzo
  • 28,358
  • 27
  • 121
  • 148
22
votes
1 answer

Prevent window redraw when resizing c# windows forms

What windows message or event can i listen to in order to stop a window from being redrawing every pixel of it's resize? That is, when a user clicks on the edge of the window and starts to re-size it, i don't want to re-draw the entire contents…
Daniel
  • 865
  • 1
  • 8
  • 12
21
votes
4 answers

'ControlLabel' is not exported from 'react-bootstrap'

Hello I'm creating a login form in react, to check the login parameters use Checkbel of the package, but when I run the code I'm thrown this exception: ./src/App.js Attempted import error: 'ControlLabel' is not exported from 'react-bootstrap'. how…
riki
  • 1,502
  • 5
  • 17
  • 45
21
votes
6 answers

Angular FormControl check if required

Is there a way to check whether control is required? The problem arose when I implemented a dedicated form field component which accepts FormControl and has not only input but also validation errors. Since some field are required it's good to let…
Sergey
  • 7,184
  • 13
  • 42
  • 85
21
votes
3 answers

react bootstrap readonly input within formcontrol

I am using react bootstrap and this framework provides some nice FormControls. But I would like to make the Input field that is generated within the FormControls to have a prop of readonly="readonly". This way, this field looks the same as my other…
user3611459
  • 3,311
  • 6
  • 16
  • 18
18
votes
7 answers

Angular 6, this.formGroup.updateValueAndValidity() not working properly

I am trying to add and remove validators in a formGroup controls based on certain condition. When I am updating the validators through formGroup.updateValueAndValidity() for whole form its not updating, where as if I am specifically applying for…
18
votes
4 answers

Cannot assign to 'value' because it is a constant or a read-only property. Angular 6

I am trying to set a value to a Mat input using FormControl In my Ts myControl = new…
Abx
  • 2,852
  • 4
  • 30
  • 50
18
votes
6 answers

Missing partial modifier on declaration ..another partial declaration of this type exists". I'm a beginner and just following the book

I'm a beginner and I'm doing an exercise following a book. Below is my code and i got this "Missing partial modifier on declaration of type 'Windowsform.Form1'; another partial declaration of this type exists". What should i do? My code is as…
user1742237
  • 189
  • 1
  • 1
  • 3
14
votes
1 answer

How to know if two text nodes are visually consecutive

I want to know if two text nodes are visually consecutive, regardless of html structure, i.e. that there isn't an empty line or any other element between both. I'm using Ranges to get the rectangles (size and position) but there is a spacing between…
jcbp
  • 475
  • 2
  • 10
13
votes
2 answers

Handle Change of FormControl React

Hey so I have a text box/FormControl that's supposed to update a field in a json in this.state. I was wondering if there was a better way to do onChange?
Patrick Duncan
  • 549
  • 1
  • 6
  • 17
12
votes
4 answers

Angular, Disable submit button using [disabled] to check form validity

I'm trying to disable a submit button using [disable]=form.controls[...].invalid condition checking. The submit button should be disabled if there is an input fields is empty or invalid. But looks like i'm doing it wrong. The button is disabled when…
Wira Xie
  • 819
  • 5
  • 24
  • 46
1
2 3
31 32