All,
I have been attempting to use a macro which generates a list of all
modifications made to a Word document past a certain date. One of the
categories (columns) included in the output list is the current text in the
document (that is, the inserted sentence which has replaced the old text).
An example of the output:
DATE PAGE TYPE OF CHANGE CURRENT TEXT
Each of these above columns (as well as each corresponding element in the
actual output) have a vbTab in between them. Without eliminating the
linebreaks in the "Current Text" data, the text will wrap around to the next
line, which throws off the formatting, should I want to paste this into
Excel, or some other table. What I'm after is keeping current text data as
one exclusive line.
I do not wish to create an output table in Word, since that makes the output
process take MUCH longer.
I have been using the following code to handle the "Current Text" data:
While (InStr(1, CurrText, vbCr, vbBinaryCompare))
CurrText = Replace(CurrText, vbCr, " ", 1, ,
vbBinaryCompare)
Wend
This works fine, except when I come across a numbered (or lettered) list. I
have tried using vbLf & vbCrLf as well, but it does not find the list
linebreaks.
Any assistance that anyone can offer on how to overcome this is greatly
appreciated!
--
Russ - 10 Jul 2007 20:37 GMT
Garbunkel,
Does this information start you on the right track?
http://word.mvps.org/faqs/numbering/liststring.htm
Using their code example, you could check each paragraph for the listnumber
part and store it in a variable.
Then concatenate the list number string and the paragraph string.
> All,
>
[quoted text clipped - 29 lines]
> Any assistance that anyone can offer on how to overcome this is greatly
> appreciated!

Signature
Russ
drsmN0SPAMikleAThotmailD0Tcom.INVALID
Garbunkel - 11 Jul 2007 21:54 GMT
Thanks Russ,
This is a good starting point. I'll try to incorporate this into the text
checking.

Signature
> Garbunkel,
> Does this information start you on the right track?
[quoted text clipped - 37 lines]
> > Any assistance that anyone can offer on how to overcome this is greatly
> > appreciated!