Go to Newpage at eighth line in body section

Hi all, I need to fix line only seven lines in body section when they have eighth line they should to show on NEWPAGE. I use Sale Invoice Line on body section. Please help me [xx(] Thanks klum

you need to count the line printed. you can do that by counting the printed lines in a variable. once you variable is greater than 7 than do currReport.NEWPAGE

Hi, Thanks naveenjain. I try to do like this Report - OnInitReport() MaxLines := 7; Sales Invoice Line - OnPreDataItem() LineCounter := 0; Sales Invoice Line - OnAfterGetRecord() LineCounter += 1; IF LineCounter > MaxLines THEN BEGIN CurrReport.NEWPAGE; LineCounter := 0; END; Page 1 it’s work well but Page 2 not work not show anything and i can not print report Anybody can help me please [:(][V][xx(] Thanks klum

Hi all, Now my report work as well [:D] I just put some thing wrong place. First I put about CLEAR(…) wrong at Sales Invoice Header, Header(1) - OnPreSection. Correct is I move CLEAR(…) at Sales Invoice Header - OnAfterGetRecord. klum [:)]