Drag-and-Drop between windows

I am migrating a personal project from 3.6 to 4.1 (using Standard Edition). Where necessary, I have changed the API calls.

I have a screen with multiple windows, and each window contains a grid. The windows are created using dhxWins.createWindow().

In v3.6 I can drag an element from one grid to another, and everything works OK.

In v4.1, although the drag event is triggered OK, the target window does not receive focus, and the drop event is never triggered.

(Tested using Chrome and FF on Ubuntu.)

We need to inspect your demo
Please, attach it (or a direct link) on support@dhtmlx.com
docs.dhtmlx.com/auxiliary_docs__ … pport.html
Plus add a link to this topic

Hi Darya

I don’t think it will be possible to provide a standalone demo: the project uses a MySQL database, and the screens are built using data in tables, using PHP. I can provide the Javascript code, if that would help.

You can provide 2-4 windows with our sample-grid xml inside :slight_smile:
The main reason of demo is reproducing behaviour. In this case we don’t need dynamic data or something else. We just need the component you asking about (i.e. window+grid) and drag-behaviour-funcion you use to achieve it

OK - that will be a lot easier :smiley:

Yes of course :slight_smile:
Plus you can create static windows too, not only grids :slight_smile:

Sometimes even making demo users can find theirs inaccuracies :slight_smile:


the sample code below reproduces the problem: The drag drop event is triggered inside a single grid, but not when the drag is over a grid in another window: (Note that the paths will need to be changed…)


Demo: Drag-and-Drop between grids in different windows html,body { width: 100%; height: 100%; margin: 0; }

Edit your code a little - try to use ti in a demo: add a style and perameters in showDragData function. Plus try to always aviod dublicated IDs (in this case i edited them too)


Demo: Drag-and-Drop between grids in different windows html,body { width: 100%; height: 100%; margin: 0; } .dhxwin_fr_cover { display: none; }

Thanks Darya

I made the changes you suggested in the demo, and it works now.
I also made some changes to my main code: The important addition seems to be:

.dhxwin_fr_cover {display: none;}

I have changed my layout view to include this for all screen renders, and so far it is working.
Many thanks for your speedy response!

Sorry, I wanted to pay your attention to it, but somehow passed. :frowning:
Yes, you are right - it is important
You are welcome!