How to call the TextImportWizard?

  • Thread starter Thread starter Tom
  • Start date Start date
I think you could open a text file and import it to only column A. Then show
that dialog.

Option Explicit
Sub testme()

Dim myFileName As Variant

myFileName = Application.GetOpenFilename("Text files, *.txt")

If myFileName = False Then
Exit Sub
End If

Workbooks.Open Filename:=myFileName

Range("a:a").Select
Application.Dialogs(xlDialogTextToColumns).Show

End Sub
 
Back
Top