Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Insert manual page breaks
Message
From
15/01/2010 01:33:55
 
 
To
All
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Title:
Insert manual page breaks
Miscellaneous
Thread ID:
01444106
Message ID:
01444106
Views:
130
I am creating a document from a text file and would like to insert a manual page break (^m) after the word 'page' in the document m.txt
the word "page" occurs about 30 times in the text file. i staggered a guess: STRTOFILE(CHRTRAN(FILETOSTR("M.txt"),"PAGE","^M PAGE"),"M.txt")') and it doesn't work. Does anyone have something else i can try?
thanks
k
#DEFINE wdToggle 9999998
LOCAL loWord, loSelection, loDocument
loWord = CREATEOBJECT("Word.Application")
loWord.Visible = .T.
loDocument = loWord.Documents.Add()
loSelection = loWord.Selection
loSelection.Font.Name= "lucida console"
loSelection.Font.Size= "9"
=STRTOFILE(CHRTRAN(FILETOSTR("M.txt"),CHR(26),''),"M.txt")')
=STRTOFILE(CHRTRAN(FILETOSTR("M.txt"),"PAGE","^M PAGE"),"M.txt")') && doesn't work
loSelection.TypeText(FILETOSTR("M.txt") )
Next
Reply
Map
View

Click here to load this message in the networking platform