I know rownumber is there and gets initialed with rownumbers:true defined in data-options.
well i was going to a different page and from there i am supposed to return on the same page on the datagrid page.
Well i resolved this after reading many topics on the forum. here to the way to correct the rownumbers
$(document).ready(function () {
var opts = $('#tt').datagrid('options');
var pager = $('#tt').datagrid('getPager');
if(pgNum.value!='' && pgSize.value!='' ){ // pgNum and pgSize hidden variable tell the which page i am and row count respectively.
opts.pageNumber = pgNum.value;
opts.pageSize = pgSize.value;
pager.pagination({
pageNumber:pgNum.value,
showPageList:false
});
}
});
EasyUI