Craig,
Try something like the code below.
HTH,
Bernie
MS Excel MVP
Public Sub TransposeImportTextFile(FName As String, Sep As String)
'Based on Chip Pearson's Code
'Modified by Bernie Deitrick June 10, 2003
Dim RowNdx As Integer
Dim ColNdx As Integer
Dim TempVal As Variant
Dim WholeLine As String
Dim Pos As Integer
Dim NextPos As Integer
Dim SaveRowNdx As Integer
Application.ScreenUpdating = False
'On Error GoTo EndMacro:
SaveRowNdx = ActiveCell.Row
ColNdx = ActiveCell.Column
Open FName For Input Access Read As #1
While Not EOF(1)
Line Input #1, WholeLine
If Right(WholeLine, 1) <> Sep Then
WholeLine = WholeLine & Sep
End If
RowNdx = SaveRowNdx
Pos = 1
NextPos = InStr(Pos, WholeLine, Sep)
While NextPos >= 1
TempVal = Mid(WholeLine, Pos, NextPos - Pos)
Cells(RowNdx, ColNdx).Value = TempVal
Pos = NextPos + 1
RowNdx = RowNdx + 1
NextPos = InStr(Pos, WholeLine, Sep)
Wend
ColNdx = ColNdx + 1
Wend
EndMacro:
On Error GoTo 0
Application.ScreenUpdating = True
Close #1
End Sub