cancel
Showing results for 
Search instead for 
Did you mean: 

How to place two tables at a time in every page in a smartform?

Former Member
0 Kudos

Hi All,

I have a requirement in a smartform where i need two tables in every page. These tables should repeat on every page with regard to the data thats getting populated in it.If one table has more data it should not push the second table completely from the page.

Can anyone please give me a solution.

Accepted Solutions (0)

Answers (3)

Answers (3)

Former Member
0 Kudos

Declare globle variable wv_flag_tab1 , wv_flag_tab2

Insert 2 tables in main window

Manage no of rows in each table by using globle variable in condition tab

1 . at start of new page initialize wv_flag_tab1 , wv_flag_tab2

2. At each loop pass increment wv_flag_tab1 , wv_flag_tab2

3. on condition table of table check wv_flag_tab1 < max_line

Former Member
0 Kudos

Hi..

Do the following..Print one table and inside the main area of the first table apply a LOOP coomand and print the second internal table in it..

I had a similar requirement and it worked..

Hope it works..

Award points if useful..

Arun

Former Member
0 Kudos

Hi Smitha,

Try with two main windows, one holding each table.

Regards,

Arun Mohan

Former Member
0 Kudos

Hi Arun,

I tried giving two main windows but the table given in the second main window is not printed at all. Can you please give me a suggestion why its so?

Thanks,

Smitha

Former Member
0 Kudos

Smitha,

Do both the tables have data?

Former Member
0 Kudos

Hi Arun,

Yes both have data.

Thanks

Smitha

Message was edited by:

Smitha Thankachan

Former Member
0 Kudos

Hi,

Create two tables in the same main window.

This works perfectly.

Reward points if found helpful

Seema

Former Member
0 Kudos

Hi

If you see in real time printing of Smartform documents like PO or SO or Invoice

we will see two tables data one is header data which will have a single record per document and Item data which will have mulitple records.

So header data is fixed in all pages and the Item data is printed in MAIN window and overflows to other pages depending on the data.

SO Item table data will be printed in number of pages where as the Header table data will pe constantly printed on the header part(top part) of every page.

so you can handle the 2 internal tables data as above

<b>Reward points for useful Answers</b>

Regards

Anji

Former Member
0 Kudos

Hi Anji,

I have to display 2 different tables with different item data and header data.

Thanks,

Smitha