PDA

View Full Version : Multi grouping problems



PramodYadav
6 Feb 2012, 2:29 AM
Hi All,

Please give me solution for solve this error, when i have drag any column in toolbar for dynamic create multigrouping then this error raises.

Ext.fly(rows[0]) is null.

tvanzoelen
6 Feb 2012, 5:27 AM
Can you post a simple code sample and show where and when this error occurs?

PramodYadav
6 Feb 2012, 10:46 PM
Code is given.

processRows : function(startRow, skipStripe){
if(!this.ds || this.ds.getCount() < 1){
return;
}
var rows = this.getRows();
skipStripe = skipStripe || !this.grid.stripeRows;
startRow = startRow || 0;
Ext.each(rows, function(row, idx){
row.rowIndex = idx;
row.className = row.className.replace(this.rowClsRe, ' ');
if (!skipStripe && (idx + 1) % 2 === 0) {
row.className += ' x-grid3-row-alt';
}
});
// add first/last-row classes
if(startRow === 0){
Ext.fly(rows[0]).addClass(this.firstRowCls);
}
Ext.fly(rows[rows.length - 1]).addClass(this.lastRowCls);
},

Ronhead
27 Feb 2012, 10:27 AM
i've same problem..
anyone knows the solution?

the code is from Ext-ALL


/**
* @private
* Adds CSS classes and rowIndex to each row
* @param {Number} startRow The row to start from (defaults to 0)
*/
processRows : function(startRow, skipStripe) {
if (!this.ds || this.ds.getCount() < 1) {
return;
}

var rows = this.getRows(),
length = rows.length,
row, i;

skipStripe = skipStripe || !this.grid.stripeRows;
startRow = startRow || 0;

for (i = 0; i < length; i++) {
row = rows[i];
if (row) {
row.rowIndex = i;
if (!skipStripe) {
row.className = row.className.replace(this.rowClsRe, ' ');
if ((i + 1) % 2 === 0){
row.className += ' x-grid3-row-alt';
}
}
}
}

// add first/last-row classes
if (startRow === 0) {
Ext.fly(rows[0]).addClass(this.firstRowCls); // IS NULL!
}

Ext.fly(rows[length - 1]).addClass(this.lastRowCls);
},


when i use MultiGrouping
thanks!