on 10-01-2008 4:06 AM
Hi all,
my requiremnet is if user goes to item of sales order and if he changes ship-to-party(WE) in partner function then i want to pick its revelent partner ( SP) which is maintend in customer master, but i am totally confused where to change since if i cange any record in xvbpa in exit MV45AFZB it is reflecting in all ie in header also.
But i want to change this change only in item level partner how can i proceed.
if you want to apply only to item then you have to mention the item number also in the xvbpa, then only it will consider for item. if the item is space then it will treat it as header partner
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
hi,
If user manually changes the sold-to-party in item level i have to pick its SP some xxxx from customer master.
here is the code
exit: MV45afzz
data : l_kunnr like vbpa-kunnr,
l_lifnr like vbpa-lifnr.
DATA: t_xvbpa LIKE vbpa.
loop at xvbpa into l_xvbpa where posnr NE '000000'.
IF l_xvbpa-kunnr <> vbpa-kunnr.
select single lifnr from knvp into L_lifnr
where kunnr = l_xvbpa-kunnr
and parvw = 'SP'.
if sy-subrc = 0.
delete xvbpa where parvw = 'SP'.
xvbpa-NRART = 'KU'.
xvbpa-updkz = 'I'.
xvbpa-lifnr = L_lifnr.
xvbpa-posnr = xvbap-posnr.
xvbpa-parvw = 'SP'.
modify xvbpa TRANSPORTING lifnr where parvw = 'SP'.
append xvbpa.
clear l_lifnr.
endif.
ENDIF.
endloop.
User | Count |
---|---|
108 | |
12 | |
11 | |
6 | |
5 | |
4 | |
3 | |
3 | |
3 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.