‎2008 May 06 7:21 AM
Hi ,
I get the error message for the following code saying "WA_EXT-VALUEPART1" and "WA_ITEMEXT" are not mutually convertible in a unicode program.
how to correct this type of error. i cannt use move-corresponding i guess as there are no common fields, that u can check by looking at those structures.
can you please help?
DATA : WA_ITEMEXT LIKE BAPE_VBAP.
data : WA_EXT LIKE BAPIPAREX.
MOVE: WA_ITEMEXT TO WA_EXT-VALUEPART1.
Regards
Sachin
‎2008 May 06 7:25 AM
Hi,
Have seen the strucures of both what you have mentioned.
Both are different.
Thats why it has given error.
Regards,
madan.
‎2008 May 06 7:28 AM
Same structure should exist for WA_ITEMEXT and WA_EXT-VALUEPART1. only then it will be successful.
Thanks
‎2008 May 06 7:29 AM
hi,
do this way ..
DATA : WA_ITEMEXT LIKE BAPE_VBAP.
data : WA_EXT LIKE BAPE_VBAP.
MOVE: WA_ITEMEXT-VALUEPART1 TO WA_EXT-VALUEPART1.
‎2008 May 06 7:39 AM
Hi Santosh,
But again wa_ext is appended to gt_extension which is of same type as BAPIPAREX.
this is used in the function module for further processing. so i cannot change the data type here right
Thanks & Regards
Sachin
‎2008 May 06 7:32 AM
Hi,
1.The assigning the move :Structure to field is not suppose to do.
2.Better to use individually or concatenate both fields of structure to one variable and assign it to Second structure field.
Eg:
MOVE WA_ITEMEXT-vbeln TO WA_EXT-VALUEPART1.
Regards,
Shiva.
‎2008 May 06 7:39 AM
Hi Sachin, if suppose your BAPE_VBAP has the following structure:
*{
VBELN VBELN_VA CHAR 10
POSNR POSNR_VA NUMC 6
.APPEND ZTS_VBAP_01 0
field1 type CHAR 18
field2 type CHAR 18
*}
DATA : WA_ITEMEXT LIKE BAPE_VBAP.
data : WA_EXT LIKE BAPIPAREX.
you have to fill the BAPIPAREX as following.
wa_ext-structure = 'BAPE_VBAP'.
wa_ext-valuepart1+0(10) = wa_itemext-vbeln.
wa_ext-valuepart1+10(6) = wa_itemext-posnr.
wa_ext-valuepart1+16(18) = wa_itemext-field1.
wa_ext-valuepart1+24(18) = wa_itemext-field2.
and you have to fill the BAPE_VBAPX also like the same way with 'X' to create or change SO fields.
Thanks.
Regards,
Jey
‎2008 May 06 7:45 AM
hi Sachin,
In that case don't change the declaration part ...but move the field that you want to move from WA_ITEMEXT workarea than moving the structure to the field which is not acceptable..
MOVE: WA_ITEMEXT-field TO WA_EXT-VALUEPART1.
Regards,
Santosh