Skip to Content
0
Former Member
Jan 09, 2010 at 02:39 AM

Control Line Items of table in Smartforms

630 Views

Hi,

Please help me out for following problem which I am facing in smartforms.

Scenario u2013 I am trying to print Bank Payment voucher, In this I am passing two internal tables from my driver program, One internal table is for header details and other internal table for Line item details.

I am Looping for header details and under the templates, I am populating header data into itu2019s appropriate places, for line item details, I am using Table and able to populate line item details, Now say my line item should print only 5 line items in one page and if there are more than 5 line items , it should print next line items on next page. when new page will start it should print header details and footer details also,

In last last row, I have put the program code where I am counting the number of line items, and below that i have put 'Command' and in command condition, I have stated that if linecnt > 5 , go to next page%2 and in page 2, I have again copied the header details but , it is not working,

In short the Flow of Smartforms is given below.

Loop (For Header details)

Template

Template

Template

Table (For Printing Line Item Details)

(row 1

row 2

program line (Whre I am counting Number of Line items

Command (Go to next page is activated )

Template ( For Printing the footer details

Page%2

Template

Template

Template

Looking out for your valuable help .

Thanks and Regards

Rani