I just got assigned some project of a fired extjs developer. In the controllers he made, I found calls like

```
this.getMyButton().toggle(true);
this.getMyContainer().getLayout()...

```

So, I just added a new form to the view (one of the things my ex colleague should have had completed by christmas) and tried to call it from the controller using

```
this.getMyNewForm().loadRecord(someStore.getAt(0));

```

and Chrome tells me that `this.getMyNewForm()` is undefined. But nowhere in the code I found a definition for `getMyButton()`.

What's the matter with that? How do I define `getMyNewForm()`?

EDIT: Question answered by the docs (<http://docs.sencha.com/extjs/4.2.2/#!/api/Ext.app.Controller-cfg-refs>), but problem still open.

Ref is defined properly in controller:

```
refs: [{
    ref       :'MyNewForm',
    selector  :'form[id=myNewForm]'
}]

```

and MyNewForm is defined properly in view

```
    items: [{
        xtype: 'form',
        header:false,
        frame:false,
        id:'myNewForm',
        items: [{

```

but it does not work when I call

```
 init: function() {
    this.control({
    });
    this.getMyNewForm().loadRecord(someStore.getAt(0));
 },

```