Forum

November 2nd, 2014
A A A
Avatar

Lost password?
Advanced Search

— Forum Scope —




— Match —





— Forum Options —





Minimum search word length is 3 characters - maximum search word length is 84 characters

The forums are currently locked and only available for read only access
sp_Feed Topic RSS sp_Related Related Topics sp_TopicIcon
jqGrid is not showing the 10th column content
08/10/2010
11:20
Avatar
strike_noir
Member
Members
Forum Posts: 12
Member Since:
14/04/2010
sp_UserOfflineSmall Offline

Hi all programmers

I have a problem when adding new column (10th column) to my grid. I have added the colNames and colModel for the grid. It appears expected in the browser, the new column was successfully added.

But...

When I tried to fill the row, using json from an url, the data showed on the grid up to the 9th column only. The 10th column is left blank.

I have tried all possible code combination that I can think of. I getting frustrated by this

Frown

This is my code for the grid

jQuery("#detFlex1").jqGrid({
    url: '<%= Html.Encode(ViewData["module"])%>/GetDetailList1',
    datatype: "json",
    altRows: true,
    mtype: 'POST',
    colNames: ['Inv No', 'Act', '<%= RmdReqVendor.BankName %>', '<%= RmdReqVendor.AccountName %>', '<%= RmdReqVendor.AccountNum %>'
                , '<%= RmdReqVendor.Valuta %>'
                , '<%= RmdReqVendor.Country %>'
                , '<%= RmdReqVendor.Branch %>'
                , '<%= RmdReqVendor.BankKey %>'
                , '<%= RmdReqVendor.Priority %>'
                , 'ase' ],
    colModel: [
           { name: 'account_id', index: 'account_id', width: 55, hidden: true },
           { name: 'act', index: 'act', width: 50, sortable: false },
           { name: 'bank_name', index: 'bank_name', width: 150,editable:true,edittype:"select",editoptions:{value:"<%= JsHelper.BankJsArray() %>"}, editrules:{required:true} },
           { name: 'account_name', index: 'account_name', width: 150,editable:true,editoptions:{size:60,maxlength:60}, editrules:{required:true} },
           { name: 'account_num', index: 'account_num', width: 100,editable:true,editoptions:{size:18,maxlength:18}, editrules:{required:true, number:true} },
           { name: 'valuta', index: 'valuta', width: 50, editable: true,edittype:"select",editoptions:{value:"<%= JsHelper.CurrencyJsArray() %>"}, editrules:{required:true} },
           { name: 'country', index: 'country', width: 80, editable: true,edittype:"select",editoptions:{value:"<%= JsHelper.CountryJsArray() %>"}, editrules:{required:true} },
           { name: 'branch', index: 'branch', width: 150,editable:true,editoptions:{size:40,maxlength:40}, editrules:{required:true} },
           { name: 'bank_key', index: 'bank_key', width: 80,editable:true,editoptions:{size:15,maxlength:15}, editrules:{required:true} },
           { name: 'priority', index: 'priority', width: 50, align:"right" },
           { name: 'ase', index: 'ase', width: 50, align:"right" }
       ],
    rowNum: 10,
    rowList: [10, 20, 30],
    pager: '#pagerFlex1',
    sortname: 'request_id',
    viewrecords: true,
    sortorder: "desc",
    caption: '<%= RmdReqVendor.BankAccountTitle %>',
    width: $('.body').width()-40,
    height: 180,
    shrinkToFit: false,
    gridComplete: function(){
        var ids = jQuery("#detFlex1").jqGrid('getDataIDs');
        for(var i=0;i < ids.length;i++){
            var cl = ids[i];
            be = "<button style='height:22px;width:20px;' type='button' title='Edit' onclick="detFlex1_edit("+cl+")" >E</button>";
            de = "<button style='height:22px;width:20px;' type='button' title='Delete' onclick="detFlex1_delete("+cl+")" >D</button>";
            jQuery("#detFlex1").jqGrid('setRowData',ids[i],{act:be+de});
        }
    },
    editurl: "<%= Html.Encode(ViewData["module"])%>/SaveDetail1"
    
});
jQuery("#detFlex1").jqGrid('navGrid', '#pagerFlex1', { edit: false, add: false, del: false, search: false, refresh: false });

And this is my json data from the url

{"rows":[{"id":"1000P50316","cell":["1000P50316","","BANK CIMB NIAGA TBK, PT","HARTATY SUSILO","50210128881"

,"IDR","Indonesia","MELAWAI KC","00220929","1","False"]}]}

Why is this happening? Everything is ok up to the 9th column...

I am very confused Frown

11/10/2010
09:43
Avatar
strike_noir
Member
Members
Forum Posts: 12
Member Since:
14/04/2010
sp_UserOfflineSmall Offline

whoops its my own fault , sorry

Forum Timezone: Europe/Sofia

Most Users Ever Online: 715

Currently Online:
60 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.com

Moderators: tony: 7721, Rumen[Trirand]: 81

Administrators: admin: 66

Comments are closed.
Privacy Policy   Terms and Conditions   Contact Information