Hi Vladsch,
I get "Microsoft JScript runtime error: 'this.getRow(...)' is null or not an object" at
Ext.grid.GridView.override({
getCell: function (row, col) {
var tds = this.getRow(row).getElementsByTagName("td");
var ind = -1;
for (var i = 0; i < tds.length; i++) {
if (Ext.fly(tds[i]).hasClass("x-grid3-col x-grid3-cell")) {
ind++;
if (ind == col) {
return tds[i];
}
}
}
}
});
because row is Nan. Code is below:
store.DataSource = ds;
store.DataBind();
RowSelectionModel model = (grid.SelectionModel.Primary as RowSelectionModel);
model.SelectedRows.Add(new SelectedRow(selected.ToString()));
model.UpdateSelection();
Coolite.Ext.Web.ScriptManager.GetInstance(HttpContext.Current).AddScript(string.Format("Ext.getCmp('{0}').getView().focusRow({1});", grid.ClientID, selected.RowIndex));
Rowselection is done but grid cannot scroll. selected.RowIndex returns the position of the entity in data source.
What may be the reason ?