Drag'n'Drop from grid to Tree

Hi everyone,

I’m trying to drag datas from a dhxGrid to a dhxTree. The online example works perfectly (of course), but I can’t see how it’s done. Here is my code :

//grid = tmpGrid
//tree = this.dossier.tree
//the enableDrag mode is already true for the tree

  dhtmlx.compat("dnd");
  tmpGrid.enableDragAndDrop(true);
  tmpGrid.gridToTreeElement = function(tree,treeID,gridID){
      alert("dragged to tree");
      return this.cells(gridId,0).getValue();
  }
  
  tmpGrid.attachEvent("onDrop", 
    function(sId,tId,dId,sObj,tObj){
      alert("item dropped");
    }
  ); 

When I’m trying the drag’n’drop, nothing is happening. I obviously forgot something, but I can’t figure what it is…
Any idea ?