Application Development and Automation 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: 
Read only

User-Exit

Former Member
0 Likes
1,416

Tcode: MIRO

Need to check a few conditions based on users of last change / created for PO & GR and then put a block for payment during invoice creation using MIRO.

What is the User-Exit that can be used for my requirement.

Thanks

Kiran

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
1,315

hi skk

am searching for MIRO (Enter Invoice). Not for MIGO.

Any Help

Thanks

Kiran

14 REPLIES 14
Read only

Former Member
0 Likes
1,315

Hello,

Make use of the BADI <b>INVOICE_UPDATE</b>

VAsanth

Read only

kiran_k8
Active Contributor
0 Likes
1,315

Kiran,

Just some additional info.run this program to check all the user exits available for a particular transaction code.

REPORT Z9 .

tables : tstc, tadir, modsapt, modact, trdir, tfdir, enlfdir.

tables : tstct.

data : jtab like tadir occurs 0 with header line.

data : field1(30).

data : v_devclass like tadir-devclass.

parameters : p_tcode like tstc-tcode obligatory.

select single * from tstc where tcode eq p_tcode.

if sy-subrc eq 0.

select single * from tadir where pgmid = 'R3TR'

and object = 'PROG'

and obj_name = tstc-pgmna.

move : tadir-devclass to v_devclass.

if sy-subrc ne 0.

select single * from trdir where name = tstc-pgmna.

if trdir-subc eq 'F'.

select single * from tfdir where pname = tstc-pgmna.

select single * from enlfdir where funcname =

tfdir-funcname.

select single * from tadir where pgmid = 'R3TR'

and object = 'FUGR'

and obj_name eq enlfdir-area.

move : tadir-devclass to v_devclass.

endif.

endif.

select * from tadir into table jtab

where pgmid = 'R3TR'

and object = 'SMOD'

and devclass = v_devclass.

select single * from tstct where sprsl eq sy-langu and

tcode eq p_tcode.

format color col_positive intensified off.

write:/(19) 'Transaction Code - ', "#EC NOTEXT

20(20) p_tcode,

45(50) tstct-ttext.

skip.

if not jtab[] is initial.

write:/(95) sy-uline.

format color col_heading intensified on.

write:/1 sy-vline,

2 'Exit Name', "#EC NOTEXT

21 sy-vline ,

22 'Description', "#EC NOTEXT

95 sy-vline.

write:/(95) sy-uline.

loop at jtab.

select single * from modsapt

where sprsl = sy-langu and

name = jtab-obj_name.

format color col_normal intensified off.

write:/1 sy-vline,

2 jtab-obj_name hotspot on,

21 sy-vline ,

22 modsapt-modtext,

95 sy-vline.

endloop.

write:/(95) sy-uline.

describe table jtab.

skip.

format color col_total intensified on.

write:/ 'No of Exits:' , sy-tfill. "#EC NOTEXT

else.

format color col_negative intensified on.

write:/(95) 'No User Exit exists'. "#EC NOTEXT

endif.

else.

format color col_negative intensified on.

write:/(95) 'Transaction Code Does Not Exist'. "#EC NOTEXT

endif.

at line-selection.

get cursor field field1.

check field1(4) eq 'JTAB'.

set parameter id 'MON' field sy-lisel+1(10).

call transaction 'SMOD' and skip first screen.

K.Kiran.

Read only

Former Member
0 Likes
1,315

hai vasath

I implemented that badi given by you.

Now I will have to update / create a PAYMENT BLOCK in invoice (MIRO) before saving. Thus invoice will not be posted and saved with this set payment block

screen field name: INVFO-ZLSPR.

Any clues on how to do this.

Thanks,

Kiran

Read only

Former Member
0 Likes
1,315

Hi,

When running MIGO, if you put a breakpoint on the FM PF_ASTAT_OPEN. This will show you the BADI/METHODS that are called.

Then BADI being MB_MIGO_BADI.

and make use of the exit MB_CF01 in the clude ZXMBCU01

This exit will be triggered when u r daving the GR.

<b>Reward points</b>

Regards

Read only

Former Member
0 Likes
1,316

hi skk

am searching for MIRO (Enter Invoice). Not for MIGO.

Any Help

Thanks

Kiran

Read only

0 Likes
1,315

hI,

Please check this user exits .

EXIT_SAPLMR1M_002

EXIT_SAPLMR1M_003

EXIT_SAPLMR1M_010

I think you can use this exit EXIT_SAPLMR1M_002 to change.

<b>Reward points</b>

Regards

Read only

Former Member
0 Likes
1,315

hai skk,

i already put a break point on those exits. but its not stopping there.

i got these exits by running the std pgm we have.

Any more inputs is highly appreciated

Thanks

Kiran

Read only

Former Member
0 Likes
1,315

HI.

Check this EXIT_SAPLMR1M_003.

Regards.

Jay

Read only

Former Member
0 Likes
1,315

I put breakpoint in all three exits:

EXIT_SAPLMR1M_002

EXIT_SAPLMR1M_003

EXIT_SAPLMR1M_010

But still No.

Any more help.

Thanks

Kiran

Read only

Former Member
0 Likes
1,315

I found the BADI.

Thanks guys, who tried to help me.

Thanks

Kiran

Read only

0 Likes
1,315

Hi,

I have the same problem..

Plz Send me the BADI code its very helpful for me.

REgards

Sudheer

Read only

Former Member
0 Likes
1,315

Solved on my own.

Read only

0 Likes
1,315

Hi Kiran

You indicated that you resolved the issue of setting the Payment Block in BADI.

Can please provide information on how you did this.

Regards

Sergaren

Read only

0 Likes
1,315

Hi Kiran,

I have a similar requirement where i need to set payment block stochastically...can you tell me how did you resolve this?

Thanks in advance

Rgrds,

Sid