Search text for CHR$(13) - split it over lines in table

G

Gina

Hi

I am having a problem to spread a text over a couple of lines as soon as a
CHR$(13) is found.

it is found but the rest of the text (could be many lines) doesn't go to the
next line in my word table.

I obviously have to get the rest of the text but I don't know how to do
this! :(
..... I would be very grateful for some code ... please help

_______________________________
If (RSText("Discription").Value <> 0) Then
strToComp= RSText("Discription")
If InStr(1, strToComp, Chr$(13)) Then
.MoveDown Unit:=wdLine, Count:=1
Else
.MoveRight Unit:=wdCell, Count:=1
.MoveDown Unit:=wdLine, Count:=1
.TypeText Text:=RSText("Discription")
End If
End If
_______________________________

Thanks,
Gina
 
G

Gina

Think I have to add some clarifing lines:

What I wanted to do is to check a text for a paragraph character
if it is found take the left part of the string (up to the paragrapf
character)
and write it to a line
go on checking for further paragraph characters in the rest of the string
left
if a further paragraph character is found read to a certain strTemp and
write it to the next line

this basically should go to the dotted line ... but actually don't have a
clou how
Gina
_______________________________
If (RSText("Discription").Value <> 0) Then
strToComp= RSText("Discription")
If InStr(1, strToComp, Chr$(13)) Then
.MoveDown Unit:=wdLine, Count:=1

---> .....................................................................
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top