Page size and marging saving RTF

General TRichView support forum. Please post your questions here
Post Reply
jma
Posts: 18
Joined: Wed Dec 07, 2005 3:44 pm
Location: Sweden
Contact:

Page size and marging saving RTF

Post by jma »

I'm adding support for saving a list of addresses as a RTF doc.
However, when the RFT gets saved I get "Letter" as page size and margins I dont like.
This application is not supposed to print or even show the data on screen so I dont have a TRVPrint and create the TRichViewEdit using code.

How can I set the page size and margins I want in the RTF file ??

/Martin
Sergey Tkachenko
Site Admin
Posts: 17559
Joined: Sat Aug 27, 2005 10:28 am
Contact:

Post by Sergey Tkachenko »

TRichView does not save page sizes and margins, so Word uses defaults when loading.
See here how to save additional information in RTF: http://www.trichview.com/forums/viewtopic.php?t=64
For paper size, the keywords are:
- paper width: \paperwN
- paper height: \paperhN
where N is size in twips (convert mm to twips as it's shown in the link above)
Post Reply