Dnx_7
asked on
How to drag drop in vb.net using ONLY windows API?
Hi experts,
i would like to implement drag drop by only using windows API,
can anyone can help?
Thank you,
Kind Regards?
i would like to implement drag drop by only using windows API,
can anyone can help?
Thank you,
Kind Regards?
ASKER
Hi idle mind,
because we need to intercept a dragged item from an external application...
we used the built-in drag drop .net but cannot detect what is the object dragged...
it is possible because another enterprise did it in C++
and the dragged item react on a Windows explorer windows...
so our possibilities are :
- simulate the windows explorer (like getting the handle and associate the handle to a form or panel... but don't really know if it is possible...à
- use the windows api drag drop to get the lower level and check the dragged item to analyze the object...
Thanks for your help,
Kind Regards
because we need to intercept a dragged item from an external application...
we used the built-in drag drop .net but cannot detect what is the object dragged...
it is possible because another enterprise did it in C++
and the dragged item react on a Windows explorer windows...
so our possibilities are :
- simulate the windows explorer (like getting the handle and associate the handle to a form or panel... but don't really know if it is possible...à
- use the windows api drag drop to get the lower level and check the dragged item to analyze the object...
Thanks for your help,
Kind Regards
What application is the source of the drag drop? What happens in explorer when that item is dropped?
ASKER
The application is a specific application for broadcast systems...
when this application init a drag drop out of his environment, it only reacts in a windows explorer otherwise, nothing happens
we infer that if we simulate the explorer then we can do something with the dropped item...
or we guess that if we use the lowest level of the drag drop (windows api) then we can catch the dragged item and do things with this..
when this application init a drag drop out of his environment, it only reacts in a windows explorer otherwise, nothing happens
we infer that if we simulate the explorer then we can do something with the dropped item...
or we guess that if we use the lowest level of the drag drop (windows api) then we can catch the dragged item and do things with this..
Did you try using the GetFormats() function in the DragEnter() event for you control?
http://msdn.microsoft.com/en-us/library/1745023c.aspx
Private Sub Panel1_DragEnter(ByVal sender As Object, ByVal e As System.Windows.Forms.DragE ventArgs) Handles Panel1.DragEnter
Dim formats() As String = e.Data.GetFormats
End Sub
Or can you not get any drag/drop events to fire at all for your app when the source item is dragged over it?
http://msdn.microsoft.com/en-us/library/1745023c.aspx
Private Sub Panel1_DragEnter(ByVal sender As Object, ByVal e As System.Windows.Forms.DragE
Dim formats() As String = e.Data.GetFormats
End Sub
Or can you not get any drag/drop events to fire at all for your app when the source item is dragged over it?
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Not really the solution but good to know
What exactly do you mean by that?
...and how does the built-in drag/drop functionality not meet your needs?