I have an Excel97 workbook which I need to copy data to from a text file. This text file is to be opened
as fixed width with specific parameters.
Easy enough when you know the name and path of the file that you are opening.
However, the text files are created and named by the user (downloaded from a mainframe system). Therefore
they could be saved anywhere with anyname.
I don't want the user to have to type the name and path into the workbook prior to running the code.
I can't use the
Application.Dialogs(xlDialogOpen).Show ("C:\"
method, as this would then require the user to choose the file type and parameters.
Is it possible to display the file open dialog, for specific file type(s) and at a specified start directory,
and for no other action to be carried out other than passing the path and filename back to a variable?
Any help would be most appreciated.
as fixed width with specific parameters.
Easy enough when you know the name and path of the file that you are opening.
However, the text files are created and named by the user (downloaded from a mainframe system). Therefore
they could be saved anywhere with anyname.
I don't want the user to have to type the name and path into the workbook prior to running the code.
I can't use the
Application.Dialogs(xlDialogOpen).Show ("C:\"
method, as this would then require the user to choose the file type and parameters.
Is it possible to display the file open dialog, for specific file type(s) and at a specified start directory,
and for no other action to be carried out other than passing the path and filename back to a variable?
Any help would be most appreciated.