cancel
Showing results for 
Search instead for 
Did you mean: 

exit MV50AFZ1

Former Member
0 Kudos

Hi,

We are using the exit MV50AFZ1 form userexit_save_document_prepare for deliveries and validate the Sale Order doesn't have any position with reason for rejection when Post Goods Issues bottom has been pressed.

The problem is when the delivery is saved or deleted the form userexit_save_document_prepare is called also.

Is there any way to tell the difference between pressing Post Goods Issues, save or delete bottom? Or when the save/delete bottom has been pressed doesn't call userexit_save_document_prepare?

Thanks

Accepted Solutions (0)

Answers (2)

Answers (2)

harry_wu
Contributor
0 Kudos

1.

T180-TRTYP means the type of transaction code.

If you run VL02n, it will alwasy be 'V' (change), no matter whether you change or delete the delivery.

So, you cannot distinguish deletion and change via this field.

2.

To distinguish changing and deletion, you can check XLIKP-UPDKZ or XLIPS-UPDKZ.

If it's 'D', system is deleting.

😧 delete

U: update

I: insert.

3.

To tell whether system is posting goods movement, maybe you can check the goods movement status in XVBUK / XVBUP.

(XVBUK-WBSTK / XVBUP-WBSTA).

Former Member
0 Kudos

Hi

Thanks for all the answers, I still hasn´t the time to try this solutions with the abbap´s boys.

I´ll try today and give you the status.

Regards,

Oscar

Former Member
0 Kudos

Hi,

Yesterday I tried to use SY-UCOMM to identify what button the user clicked and works fine with my exit.

Thanks a lot for all your answers,

Oscar

dirk_freyaldenhoven
Active Participant
0 Kudos

Hello Oscar,

check T180-TRTYP and SY-UCOMM.

Best Regards, Dirk

Edited by: Dirk Freyaldenhoven on Apr 16, 2010 2:42 PM