by the way this is of no use, and you choice of variable name is terrible

Code:
For Each file As String In dlg.SelectedPath
selected path is a path not a file and there is only one path