‎2005 Aug 24 12:58 PM
Hi folks,
need some help regarding sap scripts
i havecopied the standard layout medruck to my layout
and made some changes.
now i have to modify the driver program
in the tnapr table the driver prog for medruck is
given as sapfm06p
but when i see the source code for that in the
editor
evrthing is like included functions there
in the incuded there is a form named with "entry_neu"
which has some code calling few functions
but...
there is no openform,no write form etc.
where should i give the name of the form name that i have
i have developed(changes made to the copy of the medruck)
where should i make the changes in the prog
how about going at modifying the driver program
do i have to assign the o/p type using the tcode nace.
please give me the steps
please treat it as very urgent
expecting a promt responses from u
thanks & regards,
annamreddy
‎2005 Aug 24 1:03 PM
Hi Naveen,
When you need to customize the layout for the Purchase Order, you can copy the standard MEDRUCK form to a ZMEDRUCK Form, and then make changes only in the ZMEDRCUK form as required. YOU NEED NOT CHANGE ANYTHING IN THE DRIVER PROGRAM.
After the form modifications, Goto TCODE NACE and assign this new for to the output type of PO.
Steps:
1) Goto NACE Tcode
2) Select EF Purchase Order and click on the Output Types button on the top
3) Choose NEU and dbl click on the Processing routines on the left.
4) Now ,in this screen update the formname to ZMEDRUCK for print out.
Don't confuse urself understanding the standard print program.
Cheers,
Sam
‎2005 Aug 24 1:12 PM
Hi Naveen,
Also, there is no need for you to modify the standard print program because it will work fine even if you make a ZMEDRUCK and assign it to that standard print program. Only those fields which you feel needs to be aligned/removed will reflect in the PO layout in the print preview of ME23N according to the changes you've made in the ZMEDRUCK form.
Cheers,
Sam
‎2005 Aug 24 1:38 PM
Hi Naveen
I answered a similar question in a forum. Please check the link below for details (i got reward points for it 😞
https://www.sdn.sap.com/sdn/collaboration.sdn?node=linkFnode6-1&contenttype=url&content=https://
Regards
Ashish Jain
‎2005 Aug 24 1:50 PM
We modified the driver program because there was a requirement to add stuff that was not available in the standard driver program. Here is what we did.
First, Copied the SAPFM06P program to SAPFZM06P. Did not copy all of the includes. Copied only the FM06PE02 include program to ZFM06PE02.
Second, in the include ZFM06PE02, there is a form call ENTRY_NEU, this is the entry point to print the form, notice that there is a function module in this form called ME_PRINT_PO. This is the function module that will print the PO. Eventually, you will want to call a Z version of that funciton module.
Third, copy the entire funtion group MEDRUCK into ZMEDRUCK. This is the function group which has the function module ME_PRINT_PO. Don't copy the includes into Z versions. You don't need to modify all of them. Only copy them when needed. Save and Activate.
Finally, go back to that include program ZFM06PE02, now make the call to ME_PRINT_PO to the Z version, in my case it is ZME_PRINT_PO. Save and activate.
Make sure that you change your configuration in SPRO to use the SAPFZM06P program instead of the standard. Now your form should be printing from the custom driver program. Modify away!!!!
Please don't forget to award points for helpful answers. Thanks.
Regards,
Rich Heilman