Skip to Content
Former Member
Oct 26, 2016 at 02:37 PM

Unlock of Z table in Customer or Vendor BADIs


Hello gurus,

I have a question regarding Customer (or Vendor) transaction enhancement, using BAdi definitions 'CUSTOMER_ADD_DATA' and 'CUSTOMER_ADD_DATA_CS' (or 'VENDOR_ADD_DATA' and 'VENDOR_ADD_DATA_CS' respectively, it is the same example).

In the added tab of these enhancements, an ALV (or Table Control) has to be displayed.

That List is related to a 'Z' table of the dictionary. If an user is already working with the table, the List (or Table Control) has to appear grayed-out (in display-only mode). To do so I use a lock object of the table.

The problem is the following: How can I unlock my table, when necessary, with full confidence?

I do not find any method, in the related classes, that would be like an "on_exit" event-catcher. For instance, 'SAVE_DATA' method is triggered only if user wants to save changes.

I was based on SAP Notes '580266' and '577502'.

Thanks a lot in advance!,