Hi Semaj,
LOOP AT it_vbap1
You are trying to loop an it_vbap1 to an inbuilt workarea.But seems like you forget to add the headerline declarion in the Data statement.
Declare like this ,
DATA: it_vbap TYPE STANDARD TABLE OF t_vbapWith Header line INITIAL SIZE 0,
it_vbap1 TYPE STANDARD TABLE OF it_vbap1 With Header line INITIAL SIZE 0,
With Headerline will have an inbuilt workarea of same type.so need of declaring it again.
Try and let us know the results.hope it helps.
Regards,
Kannan