Skip, it is as I suspected...no tables. It just looks like a table.
It is VERY important to know if those spaces:
#elem 59 59 59 59 59 59 #elem
are just spaces, or tabs. Again, I suspect not.
"2) No tabs (I think)"
Be sure. Turn on Show/Hide. If they are tabs, they will show as tabs (little arrows).
So, OK, it comes down to: "3) Pre-determined chunks of text selected "
Forget about the "selected" part. It is the pre-determined that is significant. Properly done, there should be no need to
select anyway at all.
"I had hoped something would be available that would work in a grid format"
As there are no tables...there is no possibility of any grid. It is plain-text...no grid.
What is also crucial to know is if these are lines terminated by paragraph marks. Again, turn on Show/Hide and see. If they are (and it is very possible they are NOT, because this is an old plain-text output) it makes things easier. If they do NOT terminate with paragraph marks, it can still be done, but it becomes trickier.
Bottom line is as has been stated. YOU must determine what are those chunks. Here is an example:
Code:
Option Explicit
Sub Yaddagerry()
Dim rDoc As Range
Dim rChunk As Range
Dim j As Long
[COLOR=red]' set document range object[/color red]
Set rDoc = ActiveDocument.Range
With rDoc.Find
[COLOR=red]' find FIRST #elem[/color red]
.Text = "#elem"
.Execute
[COLOR=red]' set chunk range object to the START of first "#elem"[/color red]
Set rChunk = ActiveDocument.Range( _
Start:=rDoc.Start, _
End:=rDoc.Start)
[COLOR=red]' collapse document range[/color red]
rDoc.Collapse 0
[COLOR=red]' reset search to "ERNS"[/color red]
.Text = "ERNS"
[COLOR=red]' search twice to find SECOND "ERNS"[/color red]
For j = 1 To 2
.Execute
Next
[COLOR=red]' set chunk ranage object .END to end of
' second "ERNS"[/color red]
rChunk.End = rDoc.End
MsgBox rChunk.Text
End With
End Sub
This would make a range object equal to the text between the FIRST "#elem" and the SECOND "ERNS".
06-25-2009, 2:06:45 PM, xxxxxx, xxxxxxxx = 6 mils, window =
6 Random File(s) Starting with t051
Parameters
Scan# 1. 2. 3. 4. 5. 6. Scan#
[highlight]#elem 59 59 59 59 59 59 #elem
SC 506 504 502 742 745 742 SC
MEC 438 437 435 644 643 644 MEC
ERNS 10 17 13 226 221 227 ERNS[/highlight]
ERNB 13 0 0 0 0 0 ERNB
ERNQZ 10 17< 13< 0 9 8 ERNQZ
LEADQZ 1 1 1 1 1 1 LEADQZ
TRLQZ 1 1 1 1 1 1 TRLQZ
Format 15B 15B 15B 15B 15B 14B Format
Rxxx 84 84 85 90 90 93 Rxxx
Again, once you actually determine what those "pre-determined' chunks are, then you can do it.
Gerry