Hi,
One thing that caught my attention is this:
SELECT-OPTIONS: s_vbeln FOR gs_vbak-vbeln.
what happen if this value is not filled ?
and then we have :
SELECT SINGLE vbeln vkorg kunnr
FROM vbak
INTO (gs_vbak-vbeln,gs_vbak-vkorg,gs_vbak-kunnr)
WHERE vbeln IN s_vbeln.
I recommend adding to s_vbeln OBLIGATORY NO-EXTENSION NO INTERVALS
Also if this select fail issue an error message.(there are some standard ones that you can use)
Regards.