printing long rtf
Manel
Barcelona, Catalonia
Hi all,
I have to disign a repot wich must show a long rtf (40 pages, more or less). I must show a page header and a page footer that are not in the rtf too.
Becaouse the document may change frequentlly and I don't want to modify the report each time, I think the best way is loading the document into a TfrxRichView at run time, but I have 2 questions:
- The only way it seems to be to load the contents from a file is LoadFromStream.... but when I do this, I get an exception whith the text "invalid file format". Is there any other way to do this? I use next code:
-In the other hand, if I load the content at design time, the report only whow the frist page, so I have to creat manually one report page per document page an copy - paste the content... is there any way to force FR to create automatically each page depending on the document length?
I have to disign a repot wich must show a long rtf (40 pages, more or less). I must show a page header and a page footer that are not in the rtf too.
Becaouse the document may change frequentlly and I don't want to modify the report each time, I think the best way is loading the document into a TfrxRichView at run time, but I have 2 questions:
- The only way it seems to be to load the contents from a file is LoadFromStream.... but when I do this, I get an exception whith the text "invalid file format". Is there any other way to do this? I use next code:
var
 str: TFileStream;
 View: TfrxRichView;
begin
 str := TFileStream.create('a.rtf');
 View.LoadFromStream(str);
 str.Free;
end;
-In the other hand, if I load the content at design time, the report only whow the frist page, so I have to creat manually one report page per document page an copy - paste the content... is there any way to force FR to create automatically each page depending on the document length?
Comments
2) put the Rich object on a band and set Rich.Stretretched to true and Band.Stretched and Band.AllowSplit to True.
TFrxRichView dosen't have a Strechet property.. I've tried with al the possibilities in StrechMode, but th report alway sows only one page. Memo is in a MasterData Band, set to true both AllowSplit and Streched properties..... any idea?