Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

not mutually convertible in unicode program...

Former Member
0 Kudos

hi,

in my program, an structure of type BAPE_VBEP is being assigned to a field say valuepart3 in BAPIPAREX structure as follows:

l_bapiparex-valuepart3 = v_bape_vbep.

note that bape_vbep has additional fields apart from vbeln, posnr and etenr..

but during compilation, i get the error " bothe are not mutually convertible in unicode program:. what does that mean and how to resolve that..

thks

8 REPLIES 8

former_member156446
Active Contributor
0 Kudos

there might be some type miss match, with the parameter you are passing to the structure.. check them

Former Member
0 Kudos

In unicode environment you will get this error if the structures are not same.

Try moving each field individually in the required structure either by using

l_bapiparex-valuepart3-<Field1> = v_bape_vbep-field1.

Or

MOVE v_bape_vbep-fied1 TO l_bapiparex-valuepart3-field1

0 Kudos

OK..But I did not get this error in another program where the variable aa was a char 128 field and variable bb was a user defined structure with 6 fields each like char 29, char 1, char 30 etc. but all added up to 128 characters length.

so was that why aa = bb valid bcos their lengths were same ??

thks

Former Member
0 Kudos

HI,

Use this FM as it uses the Field Symbols in move data between two different structres.

CALL FUNCTION 'HR_99S_COPY_STRUC1_STRUC2'
          EXPORTING
              P_STRUCT1       = v_bape_vbep
         IMPORTING
             P_STRUCT2       = l_bapiparex-valuepart3 .

0 Kudos

Pl do note that here I am assigning an entire structure to a single field.. So the code first populates like this..

struct1-f1 = v1.

struct1-f2 = v2.

struct1-f3 = v3.

and then

struct2-fx = struct1.

so my question is how are all the fields of struct1 moved to struct2-fx. Are they concatenated or what ?

this code works very well in 4.6 but in ECC 6.0 I get unicode error.

any more help ?

Former Member
0 Kudos

resolved myself...

0 Kudos

pls. close the threads, if they are rsolved. Bcoz, u hv 44 opened threds.

thanq

0 Kudos

Hi,

What was the solution?

Thanks,

Kind regards,

Bence