Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

How to find and modify driver program in scripts

Former Member
0 Kudos

Hi every one,

I want to know the driver program of MEDRUCK form.it is SAPFM06P but it is not an executable program .if i want to modify that i need to change it as Zprogram.for that Zprogram, if i want to change and execute it,how to do that .Pls help me in this context ASAP.

Vaidehi.Y

14 REPLIES 14

Former Member
0 Kudos

hi,

Check TNAPR table PGNAM-Program name FONAM-Form name

Former Member
0 Kudos

Hi,

For finding the driver program associated with form use TNAPR table.

I think the MEDRUCK form is associated with PO for printing.

For this what u can do is create ur Z Program.

After creating this, just goto NACE transaction --> EF Application.

Select it and Click on Output Types. There depending on the output type, u can select the Processing routine and specify the Form name and the driver program name.

Hope it helps u.

Regards,

Himanshu

Message was edited by:

Himanshu Aggarwal

Former Member
0 Kudos

no you have to tun tcode ME9F to execute it. you have to copy the prog SAPFM06P to zprog and then run ME9F.'

regards

shiba dutta

Former Member
0 Kudos

Hi,

Yes, you are right, SAPFM06P is the driver program for MEDRUCK (purchase order Script).

it is not an executable program, it is triggered only when you execute the script from ME9F transaction or from ME22N tcode.

Copy the SAPFM06P program to Z program and Medruck to ZMEDRUCK and modify them and attach the both program and Script in the NACE transaction against the NEU output type.

But why you need to copy and modify the program? generally we copy the script and modify and attach in the NACE.

Unless there is something that has to be changed in the driver program, we won't copy and change.

Even you copy attach the same Zprogram in NACE,

reward points if useful

regards,

ANJI

former_member181962
Active Contributor
0 Kudos

Copy the include FM06PE02 into a z program.

Then call the form entry_neu using perform statement.

parameters: p_ebeln type ekko-ebeln.

start-of-selection.

perform entry_neu using retcode xscreen.

also pass the PO number to the NAST-OBJKY as the first statement of the form entry_neu.

Regards,

ravi

0 Kudos

HI SHIBA DUTTA AND RAVIKANTH,

Even i copied all the SAPFM06P includes into Zreport program,it wont execute shows that it is a subroutine.after that i run ME9F it wont gave me any o/p.

i copied that include also .and double click on that include i got that form but still i confused to do .so pls give me a clear idea about this

0 Kudos

just copy whole prog SAPFM06P to ZSAPFM06P and assign

your zprog with medruck in NACE or SPRO .

i have assigned it in SPRO path material management-> purchasing> messages->forms(layouts) for messages->assign form and output prog for purchase order..

regards

shiba dutta

0 Kudos

HI SHIBA DUTTA

i did that .after assigning zform and zprogram to NACE ,i execute the t-code ME9F.

but in ME9F,igave one podocument no and F8 ,select that check box and go for dispaly messages but it will not give any o/p

0 Kudos

CHECK WHETHER BOTH ARE ACTIVATED OR NOT (PROG AND SCRIPT) THEN PUT A BREAK POINT IN THE PROGRAM OR PUT DEBUGGING MODE ON FOR THE SCRIPT< BYGO TO SE71 GIVE THE FORM NAME IN THAT SCREEN MENU UTILITIES---> ACTIVATE DEBUGGER> AND CHECK WHETHER YOUR PROG AND SCRIPT ARE TRIGGERING OR NOT

REGARDS

SHIBA DUTTA

0 Kudos

the prgrame was not activated .it will give some errors in ZYFM06PE02

i placed parameters statement in that .then it will shows ME_READ_PO_FOR_PRINTING is unknown

pls help me out

0 Kudos

check is there any Inactive Includes in that Copied program ?

or check ZY for sytax .

Regards

Prabhu

Former Member
0 Kudos

Hi Vaidehi.

Basically it is subroutine pool.

Example to make it executable for PO printing.

If you want to create executable program then just copy make executable program and copy standard routine code into your program

like if you see in SAPFM06P. there is include FM06PE02.

double click on it and to find entry_neu routine Copy that code in your program.

Reward if useful.

Former Member
0 Kudos

Copy the SAPFM06P program to Z program and Medruck to ZMEDRUCK and modify them and attach the both program and Script in the NACE transaction against the NEU output type.

Former Member
0 Kudos

Hi Vaidehi,

<b>Method1</b>: In TNAPR table the driver program name and form nanes will be stored

go to se11 enter tnapr table

give the form name and execute u will get the driver program of that particular form

fields,

PGNAM - Program name

FONAM - Form name

<b>Method 2 :</b>

1. Go to nace

2. select application (eg, EA)

3. click output type button and select output type

(eg, NEU)

4. double click on processing routines

5. Application - EA

Output Types - NEU (RFQ)

Program - program name

Form - Form name

u can get there

<b>Method 3 :</b>

if u want to directly see without going to nace

1. in se11 give view name as VN_TNAPR

2. execute it

3. it will ask for o/p type and application give it

4. then u can directly go to nace "display view processing routines" screen

2. You can define variable in SAPscript by apply statement ’DEFINE’.

Example: Define variable name = ’TXT1’ and initial value = ’Text1’.

/: DEFINE &TXT1& = ’Text1’

  • Test Define Text = &TXT1&

The Output is

Test Define Text = Text1

3. loop at internaltable

call function 'WRITE_FORM'

-


-


-


endloop.

<b>

Reward all helpful answers....</b>

Regards,

V.Raghavender.