Form validation error in ionic 2. "Can't resolve all parameters for FormGroup: (?, ?, ?)"

I am trying to use forms in ionic 2. And wrote this very basic application, however, keep getting the following error: “Can’t resolve all parameters for FormGroup: (?, ?, ?)”

ts file:

import { Component } from '@angular/core';
import { NavController, NavParams } from 'ionic-angular';
import { FormBuilder, FormGroup } from '@angular/forms';

  selector: 'page-register',
  templateUrl: 'register.html'
export class RegisterPage {

  private myData: any;
          myForm: FormGroup;

  constructor(public navCtrl: NavController,
              public navParams: NavParams,
              private builder: FormBuilder) {

                this.myForm ={
                 'subject': '',
                 'message': ''


  ionViewDidLoad() {
    console.log('ionViewDidLoad RegisterPage');

  onSubmit(formData) {
   if(formData.valid) {
     this.myData = formData.value;

html file:

<form [formGroup]="myForm" (ngSubmit)="onSubmit(myForm.value)">`
              <ion-label floating>Subject</ion-label>
              <ion-input type="text" formControlName="subject" name="subject"></ion-input>

          <ion-label floating>Message</ion-label>
          <ion-textarea type="text" formControlName="message" name="message"></ion-textarea>

        <ion-icon name="add"></ion-icon>Add


I am new to ionic, has anyone dealt with this kind of issue?

As far as i know a formcontrol can receive up to 3 parameters inside an array for the validators, so you need to wrap you ’ ’ inside a []. Try:

this.myForm ={
             'subject': [''],
             'message': ['']

Still getting the same error!

Solved it, I was importing modules more than once!