2009 Mar 10 1:47 PM
I'm using method LINE_MODIFY in MB_MIGO_BADI in order to concatenate material description and size after material number choosing. Below is my code !
select single groes into p_groes
from mara
where matnr = cs_goitem-matnr.
select single maktx into p_maktx
from makt
where matnr = cs_goitem-matnr
and spras = sy-langu.
concatenate p_maktx p_groes into p_all SEPARATED BY space.
cs_goitem-maktx = p_all.
The field which I want to fill is goitem-maktx.
How to transfer value of cs_goitem-maktx to goitem-maktx ?
Stefan
I'm using method LINE_MODIFY in MB_MIGO_BADI in order to concatenate material description and size after material number choosing. Below is my code !
select single groes into p_groes
from mara
where matnr = cs_goitem-matnr.
select single maktx into p_maktx
from makt
where matnr = cs_goitem-matnr
and spras = sy-langu.
concatenate p_maktx p_groes into p_all SEPARATED BY space.
cs_goitem-maktx = p_all.
The field which I want to fill is goitem-maktx.
How to transfer value of cs_goitem-maktx to goitem-maktx ?
Stefan
2009 Mar 10 2:05 PM
Hi,
If you have passed the description in cs_goitem-maktx that is enough. It will reflect in the goitem-maktx.
2009 Mar 10 2:23 PM
Acctualy I did it, but it don't fill the field.
As you can see in my code I'm concatenating two variables in variable p_all. Afterwards I give that value to cs_goitem-maktx.
Stefan
2009 Mar 10 2:22 PM
If check the BADI defination CS_GOITEM actually holds the ref of GOITEM and this is a changing parameter in the BADi, so as Avinash said, just passed your data to cs_goitem structure, it will reflect in go item.
Kuntal
2009 Mar 10 2:32 PM
Hi,
cs_goitem holds type ref. to GOITEM and its type is "changing", but nothing happens.
When I push the button 'Signature' I can see 'Parameter CS_GOITEM' 'Type spec. TYPE GOITEM'.
Stefan
2009 Mar 10 2:37 PM
Hi again,
I did some debugging and mentioned that when IF_EX_MB_MIGO_BADI~LINE_MODIFY method ends the field cs_goitem-maktx returns its previous value ???
Stefan
2009 Mar 10 2:37 PM
I have no idea why its not happening to you. Please check whether your implementation is active or not. Are are getting some value in Goitem, or its just balnk.
2009 Mar 10 2:39 PM
Its a changing parameter, so if you change the value correctly, then it will not return the previous value.
One standard implementation of this BADI is there : OIB_MIGO_BADI_TST you can check this for your reference.
Kuntal
Edited by: Kuntal Nandi on Mar 10, 2009 9:41 AM
2009 Mar 10 2:46 PM
In debugging mode I can't check GOITEM, only cs_goitem. ???
Stefan
2009 Mar 10 3:02 PM
Dear Kuntal,
Please have a look on my code !
method IF_EX_MB_MIGO_BADI~LINE_MODIFY.
break skolev.
data: p_groes type mara-groes.
data: p_maktx type makt-maktx.
data: p_all type goitem-maktx.
data: p_len type p.
select single groes into p_groes
from mara
where matnr = cs_goitem-matnr.
select single maktx into p_maktx
from makt
where matnr = cs_goitem-matnr
and spras = sy-langu.
concatenate p_maktx p_groes into p_all SEPARATED BY space.
p_len = strlen( p_all ).
cs_goitem-maktx = p_all.
CALL METHOD cs_GOITEM->HOLD_DATA_SAVE( ).
*
*
break skolev.
endmethod.
2009 Mar 24 9:39 AM
2011 Oct 05 11:43 AM
Hi, please tell me how did you solve this problem.
Best Regards
2014 Jul 10 11:30 AM
Dear Stefan,
i am from Sri Lanka,
and also failing with same issue, update cs_goitem
but it says "BADI: you are not allowed to change the field content of GOITEM-ZZADDFIELD
how can i solved this issue?
| User | Count |
|---|---|
| 4 | |
| 2 | |
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |