cancel
Showing results for 
Search instead for 
Did you mean: 

Problem in Tax invoice printing

Former Member
0 Kudos

Hi,

In the print out of tax invoice, there are 74 pages printed for 70 customers. Whenever there is a continuation of 2 pages for a single customer, in the second page the name of the next customer is printed. For example, in page no. 35 which is a continuation of page no. 34 for the same customer(MATNR-16149) , the customer details of the next customer(MATNR-16157) is printed. But this problem does not occur when a single customer's billing document is taken as input. Please help.

Regards,

Alka Nanda

Edited by: Rob Burbank on Dec 21, 2011 1:20 PM

Accepted Solutions (0)

Answers (3)

Answers (3)

Former Member
0 Kudos

Hi,

I tried changing the smartform page break (next Page) command. But the alignment of the output is disturbed now. Can anyone suggest me anything else other than next page command for this problem?

Thanks n Regards

Alka

Former Member
0 Kudos

Hello friend,

Keep the data which is growing in the main window.

Try this i think it will solve you problem. If you still have any queries please revert back to me i will help you.

Thanks,

Sri Hari

Former Member
0 Kudos

Hi,

Can anyone suggest me a way to keep 6 number of records in first page and move rest to the next page in SAMRTFORM? I think this will solve the problem , but I do not know how to do it in templates or main window.

Regards,

Alkananda

Edited by: Alka_Nanda on Feb 2, 2012 6:06 AM

Former Member
0 Kudos

Hi friend,

Its simple.

Just use commands for giving page breaks. If you want to achieve it in template create a template with 6 Rows and then do the same you can achieve the result.

See the wiki below for handling dynamic page breaks

Link : [Dynamic page break in smart forms|http://wiki.sdn.sap.com/wiki/pages/viewpage.action?pageId=261457903]

I think this will solve your issue. If you face nay issues please revert back to me i will help you.

Thanks,

Sri Hari

Former Member
0 Kudos

Hi,

1. Create Program lines in the main area.

2. Create a variable say lv_var1 and increment it (lv_var = lv_var + 1,default the variable with '1' in the global definition).This is to find the sy-tabix value

3.Check if lv_var ge 6.and set flag lv_flag eq X.

4.Place the command node in the table->mainarea->last row->lastcell.In the command node->condition tab,place the condition lv_flag eq 'X'.

this will print 6 records in the first page and moves the successive records to the second page.

Jshree

Former Member
0 Kudos

Hi,

Check the position of the NEXT_PAGE COMMAND node in the main window.

Jshree

Former Member
0 Kudos

Hello friend,

Its a simple problem only.

Its a simple problem with windows, as all of us know the main window is the only window which will grow according to the data. So you must have give the customer details in some other window which is repeating for all the page. or the window should be placed before the main window in the page so it repeats for all the page.

Also you many think its printing the next record header because you might have used different loop for fetching header data and item data separately. Or else some other method which fetches the record for every page beginning.

Its simple to handle it. Use commands and give page breaks at appropriate things so that your issue gets solved.

Please let me know if you have any difficulties in solving this.

Thanks,

Sri Hari