We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on : Nov 16th 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Drag from TreeviewAdv onto Diagram

Thread ID:

Created:

Updated:

Platform:

Replies:

22469 Dec 14,2004 09:01 AM UTC Dec 15,2004 04:31 PM UTC WinForms 3
loading
Tags: Diagram
James Brock
Asked On December 14, 2004 09:01 AM UTC

Hi Arun, I am populating a Syncfusion.TreeviewAdv with some TreeNodeAdv nodes. I intend to drag these nodes onto my diagram which contains some symbols that I have already dragged from my symbol palette. Unfortunately when I start my drag drag from the treeview over the diagram I get "symbol" outlines appearing (i.e. the MouseTracker), even though I am not dragging a NodeCollection onto the diagram or even a SymbolModel. It appears to be resurrecting the last dragged symbol shape in the MouseTracker. I have inspected the code in Diagram.cs and it seems to be calling the UpdateDragRect method and taking no account of what is being dragged? protected override void OnDragOver(System.Windows.Forms.DragEventArgs e) { POINT ptClient = new POINT(e.X, e.Y); Window.ScreenToClient(this.Handle, ref ptClient); UpdateDragRect(ptClient.X, ptClient.Y); base.OnDragOver(e); } Is this a bug? My drag from the Treeview looks like this: private void treeStructure_ItemDrag(object sender, System.Windows.Forms.ItemDragEventArgs e) { TreeNodeAdv[] treeNodes = e.Item as TreeNodeAdv[]; if (treeNodes != null) { if (treeNodes.Length > 0) { MyObject myObj = treeNodes[0].Tag as MyObject; if (myObj != null) { DragDropEffects result = treeProjectStructure.DoDragDrop(myObj, DragDropEffects.Copy); } } } } My DragDrop event in the diagram works fine, it is just that the MouseTracker should not appear. I am using v3.0.0.19 and .NET Framework 1.1 Thanks Jimski

Administrator [Syncfusion]
Replied On December 14, 2004 05:10 PM UTC

Hi Jimski Have you taken a look at the DragDrop sample that ships with Essential Diagram? Can you post steps to reproduce this problem in that sample. Regards Arun

James Brock
Replied On December 15, 2004 06:28 AM UTC

Hi Arun, I have reproduced a similar issue in the DiagramBuilder example. It is very simple to reproduce and the same behaviour occurs in my example when dragging from my treeview. i) Run DiagramBuilder ii) Load my symbol palette (have sent this to the support email for your attention) iii) Drag a symbol from the palette onto the diagram. iv) Open windows explorer v) Drag any file onto the diagram (mine was a txt file). vi) You will notice that the square outline of the last dragged symbol appears when you drag the file over the diagram. You may also get an additional static outline appear fairly randomly on the diagram too. I understand that in the DiagramBuilder example it has not in anyway tried to handle the drag from a file, however, when running my example I have and the same thing occurs. As I mentioned in my post, I think the DragOver event in the diagram does not take into account what is being dragged and will "resurrect" the previously dragged rectangle. Thanks Jimski

Administrator [Syncfusion]
Replied On December 15, 2004 04:31 PM UTC

Hi Jimski The Diagram team has fixed this issue and the fix should be part of the release version of Essential Suite 3.0. We are testing the 3.0 version which should go out before the end of this week. Regards Arun

CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

;