Forum



10:23

06/10/2009

I am getting nuts...
Here is my Code:
$(document).ready(function() {
$("#tgrff").jqGrid({"url":"/invoice/index2", "datatype":"json", "mtype":"POST", "viewrecords":true,
"colModel":{"0":{"label":"bred8", "name":"qwe8"}},
"autowidth":true, "height":"400px", "rowNum":20,
"rowList":{"0":20, "1":40, "2":60, "3":80, "4":100},
"caption":"Tgrff", "postData":{"grid":"tgrff"}, "pager":"tgrff_pager"});
$("#tgrff").navGrid("#tgrff_pager",{"edit":false, "add":false, "del":false}, {}, {}, {});
});
I am getting: Length of colNames <> colModel!
Using JQuery 1.4.4, UI 1.8.6, jQGRId 3.8.2
Had the same problem with the previouse to.
Why?
12:50

10/08/2009

You use wrong encoding for arrays. Instead of
and
you should use arrays instead:
and
Moreover parameter "pager":"tgrff_pager" is also wrong. You mean probably "pager":"#tgrff_pager". I recommend you to use the last version of jQuery (currently 1.4.4) because it has pertormance improvemennt in working with CSS, which is relevant for jqGrid.
Best regards
Oleg
Most Users Ever Online: 715
Currently Online:
57 Guest(s)
Currently Browsing this Page:
1 Guest(s)
Top Posters:
OlegK: 1255
markw65: 179
kobruleht: 144
phicarre: 132
YamilBracho: 124
Renso: 118
Member Stats:
Guest Posters: 447
Members: 11373
Moderators: 2
Admins: 1
Forum Stats:
Groups: 1
Forums: 8
Topics: 10592
Posts: 31289
Newest Members:
, razia, Prankie, psky, praveen neelam, greg.valainis@pa-tech.comModerators: tony: 7721, Rumen[Trirand]: 81
Administrators: admin: 66