‎2008 Mar 20 2:07 PM
Hi,
We have real strange problem with the loop at XVBAP .
here is the code.
loop at xvbap into ls_xvbap where updkz ne 'D' and and ( kwmeng eq 0 or zmeng eq 0 ).
endloop.
The above loop works perfectly well but it does not fill the work area ls_xvbap.
This is real starange situation.. ls_xvbap is same as xvbap.
let me know if there is some reason for this.. i can change the code to get this work.. but i am curious to know what could be the reason.
how ever the record is copied to the xvbap header line.. but technically when you say into ls-xvbap y is the record not getting copied into this work area..
Thanks
Mahesh
‎2008 Mar 20 2:10 PM
Hi
loop at xvbap into ls_xvbap where updkz ne 'D'.
if kwmeng eq 0 or
zmeng eq 0 .
continue.
endif.
endloop.
try this if it works.
Regards,
Venkat
‎2008 Mar 20 2:18 PM
My friend , i know it will work if i change the code.
But i dont want to..
even i have tried with
loop at xvbap into ls_xvbap where updkz ne 'D'.
This also dont work.. here the problem is the record is not getting copied into ls_xvbap. there is no problem with the logic.
we have upgraded to ECC 6.0 and nothing is working in this when i loop at xvbap into some work area...
Thanks
mahesh
‎2008 Mar 20 2:22 PM
Can you provide data declaration you have used for these variables..?
It looks like you are using it in some user exit.
G@urav.
‎2008 Mar 20 2:34 PM
Yes i am using it in MV45AFZZ user exit.
This is the type
data : ls_xvbap like xvbap.
I have also tried..
data : ls_xvbap type VBAPVB.(VBAPVB is the type that xvbap is declared from).
Thanks
Mahesh
‎2008 Mar 20 2:43 PM
Dont know whethet the below code will help u..
I checked this program in my Dev Server too and then I see this code over there.. this works but they have not looped it over into another work area..
LOOP AT xkomv WHERE kposn = xvbap-posnr AND
( kschl(3) = 'ZPB' OR kschl = 'ZP%+' ) AND
kinak = space.
‎2008 Mar 20 2:47 PM
I see this problem only with this user exit.. i have tried writing a program and its working fine..
into workarea does not work at all in this user exit..
‎2008 Mar 20 2:59 PM
Yes..
There seems to be a problem in MV45AZZ.
same thing is working in other programs.
I tried
data : begin of itab occurs 125.
include structure mara.
data : end of itab.
data wa like itab.
select * up to 20 rows from mara into table itab .
loop at itab into wa where mtart ne 'FERT' .
write wa-matnr.
endloop.
and it works.
G@urav.
‎2008 Mar 20 3:02 PM
Yes. it works for me too..
That is what i want to understand.. what chould be the probelm with MV45AFZZ.
‎2008 Mar 20 3:06 PM
‎2008 Mar 20 3:08 PM
I don't have that user-exit in my system
Is xvbap declared in the tables section?
Have you tried to loop with the header line if that's the case?
‎2008 Mar 20 3:17 PM
I have tried all this code..
loop at xvbap into ls_vbap..
endlooop.
This statment works all other also works xvbap has a header line that is getting filled.. but its not fillings ls_vbap this is my concern...
‎2008 Mar 25 8:00 PM
Did not get any answer.. But for sure there sould be something thing in this.. and may be particular to this user exit