When I write this
SRichViewEd.RVHeader.Clear;
SRichViewEd.RVHeader.Style:=RVStyle;
SRichViewEd.RVHeader.InsertTextW(PROP_BUSINESS_YEAR_AND_PERIOD+ #13#10,false);
SRichViewEd.RVHeader.AddBreak;
SRichViewEd.RVHeader.AddTextBlockNLA('PROP_BUSINESS_YEAR_AND_PERIOD',1,1);
SRichViewEd.RVHeader.Repaint;
only this appears:
Business:My 01.01.2014-31.12.2014
So when i click in the header und press the enter, all the text appears
Business:My 01.01.2014-31.12.2014
PROP_BUSINESS_YEAR_AND_PERIOD
How can I do, that show them all without clicking in the header?
Thanks,
Leroy
Data in header
-
- Site Admin
- Posts: 17521
- Joined: Sat Aug 27, 2005 10:28 am
- Contact:
You use both an editing-style method (InsertTextW) and viewer-style methods (AddTextBlockNLA and AddBreak).
Viewer-style methods require reformatting, call
SRichViewEd.RVHeader.Format instead of Repaint.
InsertTextW should not be used for document generation (this is an undoable method, and calling viewer-style methods after editing-style methods damage undo buffer). Change InsertTextW to Add*** method.
Also, do not assign RVHeader.Style directly; assign ExternalRVStyleHeader property instead.
Viewer-style methods require reformatting, call
SRichViewEd.RVHeader.Format instead of Repaint.
InsertTextW should not be used for document generation (this is an undoable method, and calling viewer-style methods after editing-style methods damage undo buffer). Change InsertTextW to Add*** method.
Also, do not assign RVHeader.Style directly; assign ExternalRVStyleHeader property instead.