‎2005 Aug 22 8:17 AM
Hi Guys,
I know this could be regular posting from others but it seems that i can't any solutions around.
The Problem is about printing multiple copies from Billing Document at a time. What user requested was to have the word "Original" in the first copy and the subsequent copies will have the word "COPY". i know that this can be done in SAPScript by modifying the print program but how about Smartforms???
I tried NAST (IS_NAST) table as passed by smartform but the field ANZAL seemed to return '2' when i need 2 copies. How do i know when is printing the first copy and when is printing the subsequent copies? any status from any tables indicating i am printing the first or the subsequent copies? Tried NACH but it didn't help much neither....
Please help!!!!!! Thanks a lot....
Cheers,
Andrew
‎2005 Aug 22 8:20 AM
Hello Andrew,
Just give a parameter to your SmartForm function module, and in this parameter just set a flag to know if this the first page.
In the Smartform, you just have to check the value of the parameter and if the value equal X you set 'ORIGINAL'.
Regards
Frédéric
‎2005 Aug 22 8:31 AM
Hi Frédéric,
It seems abit tough to understand it technically, how can i create the parameter for the FM? are you able to show some examples to me as i not quite familiar with smartform. Thanks a lot for the trouble.
Cheers,
Andrew
‎2005 Aug 22 8:38 AM
Ok,
so transaction SMARTFORMS
set the name, press CHANGE
Select Form Interface (in the tree)
You are in the Import parameter, you have to create one import parameter. Choose a name for example WV_TYPE, with assignment TYPE and reference CHAR1.
After this just generate the function module.
And now, when you will show the new function module you have the WV_TYPE parameter that is present.
So, in the Text_Element or anything else you just have to set in the Conditions the test WV_TYPE = 'X' to display this Text_Element
I hope it's clear (sorry for my english)
Frederic
‎2005 Aug 22 9:09 AM
Hi Frederic,
You are certainly quick in replying the thread. Your post is very detail as well. i did try but when i tried to print the second message (2nd copy) it just go back to normal, even i set 'X' in the variable. if we are printing multiple pages then is ok.
Cheers,
Andrew
‎2005 Aug 22 9:12 AM
The solution that I gived to you, just work with multiple printing. If you want that system remember that you have already print the document, you have to check that the message type for the document number already exist in the NAST table.
‎2005 Aug 22 9:34 AM
&SFSY-PAGE& for the current page number
&SFSY-FORMPAGES& for the total number of pages in the form
&SFSY-JOBPAGE& for the total number fo pages in all forms in the print job