Hi;
We used srichview component to an editor and a report tool.
When using report tool we filling some data from database to editor. Some of our report are page based, some of report are line based.
Using page based report; after fiiling a page we insert a pagebreak and new report template from a file (or database). But we can not any different pagebreak code. Our code look like this;
..... FORMRTF.SCALERV.RICHVIEWEDIT.ENDITEMMODIFY(XITEMNO,XDATA);
FORMRTF.SCALERV.RICHVIEWEDIT.CLEARUNDO;
FORMRTF.SCALERV.RICHVIEWEDIT.SETSELECTIONBOUNDS(FORMRTF.SCALERV.RICHVIEWEDIT.ITEMCOUNT-1,0,FORMRTF.SCALERV.RICHVIEWEDIT.ITEMCOUNT-1,0);
FORMRTF.SCALERV.RICHVIEWEDIT.INSERTTEXT(' '+CHR(13));
FORMRTF.SCALERV.RICHVIEWEDIT.INSERTPAGEBREAK;
FORMRTF.SCALERV.RICHVIEWEDIT.INSERTTEXT(' '+CHR(13));
FORMRTF.SCALERV.RICHVIEWEDIT.SETSELECTIONBOUNDS(FORMRTF.SCALERV.RICHVIEWEDIT.ITEMCOUNT-1,0,FORMRTF.SCALERV.RICHVIEWEDIT.ITEMCOUNT-1,0);
FORMRTF.SCALERV.RICHVIEWEDIT.INSERTRTFFROMFILEED(XXPROGDIR+'TEMP\'+XFILE);
.....
But we can'not see any pagebreak at the report. We saw only two line ( two chr(13).
Have you got any idea to solve this problem ?
Thanks ;
Pagebreak problem ?
-
- Site Admin
- Posts: 17557
- Joined: Sat Aug 27, 2005 10:28 am
- Contact:
I confirm this is a bug in TRichViewEdit: inserting item at the beginning of page removes the page break.
It will be fixed in the next update.
Quick fix: open RVERVData.pas, add after the line 1767 (info.BR := GetItem(InsertPoint).BR;):
It will be fixed in the next update.
Quick fix: open RVERVData.pas, add after the line 1767 (info.BR := GetItem(InsertPoint).BR;):
Code: Select all
info.PageBreakBefore := GetItem(InsertPoint).PageBreakBefore;