I'm using jqGrid PHP. When adding a new row (inline mode), how can I pre fill the new row using the same cell data with the last selected row? Thanks so much.
Asked
Active
Viewed 3,822 times
1 Answers
5
You can use a global variable to get the values from last selected row in onSelectRow event like this.
var lastsel= jQuery('#grid').jqGrid('getGridParam','selrow');
Now while adding a new row you can use addRowData like this
$("#grid").addRowData(rowid,data, position, srcrowid);
where data, you can get from lastsel var.
See this for further reference.

Community
- 1
- 1

Piyush Sardana
- 1,748
- 4
- 19
- 33