cancel
Showing results for 
Search instead for 
Did you mean: 

How to print different title on each copy in SAP Smartforms which is using standard print program called RLB_INVOICE like original , duplicate,triplicate and so on (given in number of messages).)

Former Member
0 Kudos

Hi All,

I want to know how to print different title on each copy of invoice in sap smartforms which is using standard print program called RLB_INVOICE . By giving number of messages say 4 while printing the document, it creates four copies . Title on each copy should be different.

I Tried below procedures till now but i didnt get result which i m looking for..

1. I Created Copies window and used sfsy-copycount like below:

Case Sfsy-Copycount

when 1 :

Orginal

when 2:

duplicate

.

.

.

End case

got result printing title 1 i.e.. original on all copies

2.I created copies window and used NAST-ANZAL

Case NAST-ANZAL

when 1 :

Orginal

when 2:

duplicate

.

.

.

End case

got result printing title 4 i.e.. last title on all copies...

3.I used Jobpages  and i got result printing title 1,2,3,4 on first copy itself(instead title 1 on first copy,title 2  on second copy...)

Could you please let me know how to solve this problem .

Thanks in Advance

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi Pinky,

Go to the table NAST-OBJKY=VBRK-VEBLEN and check if NAST-VSTAT=0  print " Original"

else NAST-VSTAT not equal to zero print " Duplicate" in the header.

Regards,

Meghna

Former Member
0 Kudos

Hi Meghna,

Thanks for the reply... Actually SFSY-COPYCOUNT it self worked for the above issue.

Issue is that smartform is using standard RLB_INVOICE and it had ls_control_param-no_dialog as 'X' , which does not allow dialog pop up for  user to give the number of Copies .Thus giving same title on all 4 copies (user selecting 4 copies in print options where sfsy-copycount does not trigger).

So created customized program by copying standard program and before calling function lf_fm_name jus gave ,for particular condition type

ls_control_param-no_dialog = ' '

ls_composer_param-tdcopies = '004'(for 4 copies)

And thus solved this issue. Now Prints different titles on different copies..

Answers (0)