Categories | Question details Back To List | ||
subgrid reload data Hi Currently the subgrid object loads the data (php script) only once during initialization. I would like to load new data for subgrid each time it's opened. Is it possible to achieve? Thanks Answer posted by Support on Sep 19, 2008 06:27 Grid API doesn't allow to reload sub grid. You can try to use onSubGridCreated to reload grid when sub grid opens first time: mygrid.attachEvent("onSubGridCreated",function(sgrid,id,index){ sgrid.clearAll(true) sgrid.loadXML("new.xml",function(){ sgrid.callEvent("onGridReconstructed",[]) }) }) But this event will be called only once. Answer posted by gabriel on Sep 19, 2008 06:36 Thanks for response. I've found a better way which reloads the grid everytime the cell is clicked. Hope it helps someone.. mygrid.attachEvent("onEditCell",function(stage,rid,cid){ if(stage==0 & cid==2) {subgrid.clearAll(false);subgrid.loadXML("php/get_users.php");} }); |