11-11-2011, 04:17 PM
How to do it?
1)Enable AllowDrop Property of the textbox.
2)Put the following code in DragOver Event of the textbox:
Code:
If e.Data.GetDataPresent(DataFormats.FileDrop) Then e.Effect = DragDropEffects.Copy
3)Put the Following code in DragDrop Event of the Textbox:
Code:
Dim data As Array = DirectCast(e.Data.GetData(DataFormats.FileDrop), Array)
Textbox1.Text = data.GetValue(0).ToString