PDA

View Full Version : Problem in MVC tutorial



scottseeker
10 Dec 2013, 6:53 PM
I'm at the portion where you are making a grid editable ...&lt;br&gt;<br>
&lt;br&gt;<br>

editUser: function(grid, record) {&lt;br&gt;<br>
&amp;nbsp;&amp;nbsp; var view = Ext.widget('useredit');&lt;br&gt;<br>
&amp;nbsp;&amp;nbsp; view.down('form').loadRecord(record);&lt;br&gt;<br>
});
It sounds like from the error messages that view.down('form') is returning undefined. &lt;br&gt;<br>

firebug:
TypeError: view.down(...) is null
view.down('form').loadRecord(record);

chrome:
Uncaught TypeError: Cannot call method 'loadRecord' of null

scottseeker
10 Dec 2013, 7:25 PM
I fixed the error, it was in the JSON for building my edit form.

Gary Schlosberg
12 Dec 2013, 7:31 AM
Glad to hear you found the issue, and thanks for taking the time to post a follow-up.