Search code examples
extjssencha-touch-2sencha-architect

Initialize Function, Adding component to container


here is a code sample which should have worked but didn't

var rows=[];
for(var i=0; i<5;i++)
{
   rows.push(Ext.create(Prototype.view.RowModel));
}
this.add(rows);

It only adds one row when it should add 5.

Why? tried it with different ID for each row, still didn't make me have more than one.

RowModel code Container Code


Solution

  • For some reason, it does not work with panel containers, but if I use a simple container it does. For me it's problem solved, but it would be interesing to know why it does not work with panels.