# Ionic select does not auto select value with Angular form builder

**URL:** <https://forum.ionicframework.com/t/ionic-select-does-not-auto-select-value-with-angular-form-builder/102392>\
**Category:** ionic-v3\
**Created:** [August 18, 2017, 4:10am UTC](https://forum.ionicframework.com/t/ionic-select-does-not-auto-select-value-with-angular-form-builder/102392 "2017-08-18T04:10:00Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![menshinobi](https://avatars.discourse-cdn.com/v4/letter/m/3da27b/32.png) [@menshinobi](https://forum.ionicframework.com/u/menshinobi)\
**Post date:** [August 18, 2017, 4:10am UTC](https://forum.ionicframework.com/t/ionic-select-does-not-auto-select-value-with-angular-form-builder/102392/1 "2017-08-18T04:10:00Z")

</div>

Here is my code

```auto
import {Component} from "@angular/core";
import {ViewController, Events} from "ionic-angular";
import {FormBuilder, Validators} from "@angular/forms";

export class AccountEditModalPage {
    form: any;
    constructor(private viewCtrl: ViewController,
                private ionic: IonicUtilProvider,
                private formBuilder: FormBuilder) {
   }
   ionViewWillLoad() {
        // Validate user registration form
        this.form = this.formBuilder.group({
            gender: ['male', Validators.required],
        });

        _.each(this._user, (value, key) => {
            if (this.form.controls[key]) {
                this.form.controls[key].setValue(value);
            }
        });
    }
}

```

and on my html page

```auto
<ion-item>
                <ion-label stacked>{{'Gender' | translate}}</ion-label>
                <ion-select formControlName="gender">
                    <ion-option value="male">{{'Male' | translate}}</ion-option>
                    <ion-option value="female">{{'Female' | translate }}</ion-option>
                </ion-select>
            </ion-item>

```

The problem is the ionic select does not select the option although the form control has the correct value. Is it Angular bug or Ionic bug?

---

<div class="post-metadata">

**Author:** ![gu\_batista](https://sea1.discourse-cdn.com/ionicframework/user_avatar/forum.ionicframework.com/gu_batista/32/114029_2.png) [@gu\_batista](https://forum.ionicframework.com/u/gu_batista)\
**Post date:** [September 13, 2017, 7:03pm UTC](https://forum.ionicframework.com/t/ionic-select-does-not-auto-select-value-with-angular-form-builder/102392/2 "2017-09-13T19:03:32Z")

</div>

Got the same error,

.
