Want to move all rows data from one grid to another grid.

I want to move all rows data from one grid to another grid onclick of button,

is there any functinality available for this?

how can i select all rows from grid??
we just have "gridobj.getCellText(text,col,row);" for cell text.

how to get all rows?
July 2,
Here's an example Alex posted a while back. Its similar to what you want -
July 2,
Yes, as Anthony said, this is the example you must take as reference.
Just need a few adjusts to make it work with "all rows selected".

PLS Note that I removed obj1.deleteRow(a[i]); which is causing interferences for multiple rows selection and replaced with a single obj1.setRowIndices([]); to clear souce grid-rows, but need a few extra lines if you need to completely clean the source grid.

Note2 : does NOT work in opposite direction. Adjust the function toSource() in same way if needed.
function toTarget(){
//var a = obj1.getSelectedRows(); //REMOVED 
var a = obj1.getRowIndices(); //NEW

for(i=0; i<a.length; i++){
//  obj1.deleteRow(a[i]); //REMOVED

obj1.setRowIndices([]); //NEW

label.setControlText("Target: " + obj2.getRowIndices());
July 2,
thanks. its working now.
July 3,

This topic is archived.

See also:

Back to support forum