Changing Defaults on Text Editor in Excel 2000

Ejohnson

New Member
Joined
May 20, 2003
Messages
14
I download 6 text files daily and open them in Excel. They are pipe ( | ) delimited but the default in Text Editor is comma ( , ) delimited. How can I change or add the pipe delimiter as a default?
 

Excel Facts

Who is Mr Spreadsheet?
Author John Walkenbach was Mr Spreadsheet until his retirement in June 2019.
Hi Erik,

Since you do this so often (daily) to so many files (6), I recommend that rather than changing the default you write a macro to read all 6 files using the | delimiter. This could reduce the entire affair to a single click.

Damon
 
Upvote 0
The six files have different names each day. I don't know how to make a macro that lets you choose the files to open during the macro.
 
Upvote 0
Use the GetOpenFilename dialog.

Code:
Sub OpenFile()

Dim f as Variant

f = Application.GetOpenFilename

If f <> "False" Then Workbooks.Open Filename:=f

End Sub
 
Upvote 0
Or if you wanted to open multiple files at once, you could use this code (or some version of it).

Code:
Sub OpenFile()

Dim f As Variant

f = Application.GetOpenFilename(MultiSelect:=True)

If IsArray(f) Then

    For i = 1 To UBound(f)
        Workbooks.Open FileName:=f(i)
    Next

ElseIf f <> "False" Then

    Workbooks.Open FileName:=f

End If

End Sub
 
Upvote 0

Forum statistics

Threads
1,221,701
Messages
6,161,381
Members
451,700
Latest member
Eccymarge

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top