Hello Gurus,
Good day.
I would like to ask for some help in finding a user exit/enhancement point to update VBRK/VBUK for our SD issue during VF01/VF04(invoice creation)
Overview:
I am working in an enhancement for SD invoice creation in which I need to check if an invoice (to be generated) has a valid combination from a custom table.
If not valid, then I need to do 2 things:
1. I need to suppress the invoice list creation so it would not show in VF24 (invoice list)
Now, done with that, I put my code inside the second highlighted box - inside PERFORM INDEX_VKDFS_AUFBAUEN_FAKTURA
If there is no valid combination from my custom table for the invoice that I am currently processing then no invoice list creation will take place.
2. I would also need to update 2 tables VBUK() and VBRK with below fields since the invoice list will be suppressed.
VBUK-RELIK - to remove the invoice list relevance for the invoice
VBRK-FKART_RL- Invoice list type
VBRK-FKDAT_RL- Billing date for the invoice list
More info/ What I did:
*At first, I place my code in the user exit (highlighted in 1st box) however, the CALL CUSTOMER FUNCTION '004'
has only exporting parameters for both LVBRK and VBUK WA so any changes that I made inside the exit will not be brought outside.
So I placed my code inside the second highlighted box - PERFORM INDEX_VKDFS_AUFBAUEN_FAKTURA.
and cleared the 3 fields mentioned.
Upon going outside to the calling FM of subroutine RK - FM RV_Billing_index_Add.
I did modify internal tables FXVBRK & FXBUK to reflect the changes made for the 3 fields.
However, when I finish the VF01/VF04 transaction and then I check VBRK/VBUK in se16, the 3 fields still has a value.
Next action:
I think the exit where I did the suppression is OK as I am able to achieve the 1st goal.
However, I need to find a suitable place to clear VBRK/VBUK entries for my 3 fields.
been checking for 2 days but I cannot find it.
Hope you encountered the issue and can give some light.
Thank you so much!
Maki