Quick question - Grid to Tree Drag and Drop

Hi All



Well, All my other items are pretty much resolved.



What I need to know is the following.



what can I do to stop drag and drop from the grid to a folder if the folder is the container of the grid display



What I mean in more clearity is



I have an inbox, the inbox when selected populates the grid. If I drag and drop from the grid into the inbox the item disappears from the grid. I do need the ability to use drag and drop to other folders so disabling is not an option fully



I figure, based on how good your software is, this won’t be an issue but figured I should ask



Also, I need to know how to stop from moving items from say the inbox grid into the sent items grid and vice versa.



Thanks



James Mackinnon

Grid provides two events
- onDragIn
- onDrag
both of which can be used to control rules of d-n-d


In your situation you probably has some war , which store ID of folder loaded in grid, so you can add to code of tree the next statement

tree.attachEvent(“onDragIn”,function(sid,tid){
    if (tid==CURRRENT_ID) return false;
    return true;
});

where CURRRENT_ID is a variable which stores current selected folder.