Hello, I am working environment is ASP.NET MVC 4, View Engine is Razor,
jQuery version is 2.0.3
jqGrid package version is 4.4.4
jQuery and jqGrid are using Nuget installed VisualStudio 2010
There is a paragraph in the View Page add JavaScript in jqGrid
var jsonStr01 = $.parseJSON('[{ "UserId": "User 01 ", "UserPwd": "12345671 ","Did":"1234561"}]');
var jsonStr02 = $.parseJSON('[{ "UserId": "User 02 ", "UserPwd": "12345672 ","Did":"1234562"}]');
$("#MyJqGrid").jqGrid
({
datatype: 'json',
height: 250,
colNames: ['User ID', 'User Pwd','OID'],
colModel: [
{ name: 'UserId', index: 'Userid', width: 100 },
{ name: 'UserPwd', index: 'UserPwd', width: 100 },
{ name: 'Did', index: 'Did', width: 100 }
],
autowidth: true,
height: "100%",
gridview: true,
multiselect: true,
pager: '#pager',
rowNum: 10,
rowList: [10,20,30,40],
sortname: 'UserId',
sortorder: "asc",
viewrecords: true,
caption: "Form Detail"
});
$("#MyJqGrid").jqGrid('addRowData',1, jsonStr01);
$("#MyJqGrid").jqGrid('addRowData',2, jsonStr02);
This is very strange MyJqGrid jqGrid displays only jsonStr01 this value rows.
No matter how many rows of data to increase addRowData, forever on the screen will only show the first time MyJqGrid increase row.
Anybody know how to solve this problem plugs do?
Thanks reply.
Copyright 2014 TriRand LtdAll Rights ReservedRSS
Back to Top