Hi, i have this code where when you drag&drop a file to the textbox it gets the path of the file.
This works great, however i want to get just the filename not the full path.
How would i do this ?
Thanks for any helpCode:Private Sub TextBox1_DragDrop(ByVal sender As Object, ByVal e As System.Windows.Forms.DragEventArgs) Handles TextBox1.DragDrop Dim Files As String() = CType(e.Data.GetData(DataFormats.FileDrop), String()) TextBox2.Text = Files(0) End Sub


Reply With Quote