If OpenFileDialog1.ShowDialog = Windows.Forms.DialogResult.OK Then
Dim filePathName As String = OpenFileDialog1.FileName
Dim count As Integer = filePathName.LastIndexOf("\")
‘目录名
Dim filePath As String = filePathName.Substring(0, count)
‘文件名
Dim fileName As String = filePathName.Substring(count + 1)
End If