on 06-04-2012 11:29 AM
How to create two copies of sap script one as original and the other one as copy of original?
Can anyone please help me out to resolve this issue?
Hi Geetha,
please change ur code as below :
data: WA_count type nast-anzal.
WA_count = nast-anzal.
/: Box frame 10 tw
* If &WA_count& EQ '1'
ph Company copy
* Else
PH Customer copy
* Endif.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Sangeetha,
Just try below code now :
WA_count = 1. *------ write this stmt inside driver prog above LOOP stmt and pass the *------ value to script using FORM-PERFORM.
inside script, use below code
/: Box frame 10 tw
* If &WA_count& EQ '1' *------ For first iteration WA_count = 0 and for next will be 1
ph Company copy
/: &WA_count& = &WA_count& + 1.
* Else
PH Customer copy
* Endif.
Hi Geetha,
While calling the OPEN_FORM Function module, generally we do not pass the structure "OPTIONS". But if you pass this structure, it has a field "TDCOPIES". here you can mention how many copies you want to print.
ONly thing is that, if you want to print any specific window only on original and not on the copies, then that you need to handle separately.. hope this helps
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Getha,
In order to print 2 copies of document , you need to add check on every window to check if it how many times page window is printed.
For that you may use a variable gv_copy in each window which will get incremented at each loop.
Now use Do while loop such that Page windows will be printed while gv_copy < 3.
Also you can make use of nast-anzal to distinguish between Origina l( nast-anza = 1) and Duplicate copy.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
95 | |
11 | |
10 | |
9 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.