-
I just added drag and drop support for local files. It is realy great. Now I want to be able to drag a link from IE, I am not worried about Netscape as much, into my program and be able to take the link. I have seen it done in download managers like Getright. I know it can be done. Any ideas?
-
set your form's OLEDropMode to manual and use this code to get the URL
Code:
Private Sub Form_OLEDragDrop(Data As DataObject, _
Effect As Long, Button As Integer, _
Shift As Integer, X As Single, Y As Single)
MsgBox Data.GetData(vbCFText)
End Sub
-
That is realy great. I had drag and drop support for files as well, is there a way to integrate the two? When I drag a file from my desktop it says it is the wrong type. If there isn't a way I will just have to put this part on a seperate, small, form. Thanks again!
-
try this for the code in the same event:
Code:
If Data.GetFormat(vbCFText) = True Then
MsgBox Data.GetData(vbCFText)
ElseIf Data.GetFormat(vbCFFiles) = True Then
'do something
End If
You can use any of the ClipBoardConstants to check what type of item is being dropped.
Tom