Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

ABAP - Incompletion Log updation - Adding fields to xVBUV

Hi,

I managed to populate the xVBUV table for specific customized fields which couldn't be maintained in the Incompletion procedures. The following code was used to populate the xVBUV table in the FORM "USEREXIT_CHECK_VBAK" :


   CONSTANTS : lc_insert LIKE xvbuv-updkz VALUE 'I',
                         lc_flag   LIKE xvbuv-msgkz VALUE 'X',
                         lc_sort   LIKE xvbuv-sortf VALUE '0010'.

   FIELD-SYMBOLS : <fs_xvbuv> LIKE LINE OF xvbuv.

   APPEND INITIAL LINE TO xvbuv ASSIGNING <fs_xvbuv>.
   MOVE sy-mandt   TO <fs_xvbuv>-mandt.
   MOVE pv_posnr   TO <fs_xvbuv>-posnr.     "The Item number where its incomplete
   MOVE pv_tbnam   TO <fs_xvbuv>-tbnam.   "Table name of the missing field(VBKD)
   MOVE pv_fdnam   TO <fs_xvbuv>-fdnam.    "Actual field name(PLTYP)
   MOVE tvap-fehgr TO <fs_xvbuv>-fehgr.       "Incompletion Procedure(i took the dynamic one)
   MOVE tvap-stgap TO <fs_xvbuv>-statg.
   MOVE lc_insert  TO <fs_xvbuv>-updkz.
   MOVE pv_fcode   TO <fs_xvbuv>-fcode.     "Function Code(this is working perfectly fine)
   MOVE lc_flag    TO <fs_xvbuv>-msgkz.
   MOVE lc_sort    TO <fs_xvbuv>-sortf.


Everything is working fine when i check the incompletion log while creation of the Sales Order through VA01. But the moment i click on save and though it gives a pop-up mentioning that the document is incomplete. I click on SAVE anyways and it saves the incomplete document.


Now if try re-editing it using VA02, it displays the following error message "Field PLTYP is not defined in incompletion procedure Y2".


I can understand that its obviously not defined in the incompletion procedure, precisely the reason why I am adding it through code. But is there anything I am missing here, coz its working perfectly in case i dont save it and check for incompletion while creating the document itself, then why the error while changing it, is out of my understanding.


Any help will be appreciated.

Tags:
Former Member
Former Member replied

HI Friends,

     Figured out the reason for the error message.

     SAP Support pack has an enhancement done in SAPLV45F(LV45FFUV) to check if the incompletion log entry done through ABAP for a particular Incompletion Procedure exists in the table TVUVF or not. In case the entry doesn't exist, the standard code throws an error. Hence the dialog message.

     Trying to figure out a way to overcome this issue. But atleast i could get to the root of it. Thanks all for your time and efforts.

Thanks and Regards,

Vadid

0 View this answer in context
Not what you were looking for? View more on this topic or Ask a question