HELP!! TEXT FILE OPEN MACRO SNAG AT DELIMIT FUNCITON.


Posted by MILAN on September 24, 2001 6:51 AM

First Portion of macrow shown below.
See below >>>>>> = snag point
_________________________________________________________
Sub auto_open()
'
' auto_open Macro
' Macro recorded xx/xx/xx by xxxxxxxx
'
fileToOpen = Application.GetOpenFilename("text files (*.txt),*.txt")
If fileToOpen <> False Then
MsgBox "Open" & fileToOpen
Workbooks.OpenText FileName:=fileToOpen, origin:=xlWindows
>>>>> StartRow:=1,DataType:=xlDelimited, TextQualifier:=xlDoubleQuote, _
ConsecutiveDelimiter:=False, Tab:=True, Semicolon:=False, Comma:=True, _
Space:=False, other:=False, FieldInfo:=Array(Array(1, 2), Array(2, 2), Array( _
3, 2), Array(4, 2), Array(5, 9), Array(6, 2))
Rows("1:1").Select
Selection.Delete Shift:=xlUp
Selection.End(xlToRight).Select
Range("A1:E200").Select
Selection.RowHeight = 27.25
With Selection
.HorizontalAlignment = xlGeneral
.VerticalAlignment = xlTop

ETC ETC ETC.....
End sub
_____________________________________________________________



Posted by Paul W on September 24, 2001 7:25 AM

auto_open Macro Macro recorded xx/xx/xx by xxxxxxxx ETC ETC ETC..... End sub ____

Try changing your Array(5,9) to Array(5,2)