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: 

abap - incompatible type error

Former Member
0 Kudos

Hi Experts,

I got the requirement to change spell_amount function module into Z_SPELL_AMOUNT Function module. Sap has givin some modifications in spell_amount function module. so i have done those changes in Z_SPELL_AMOUNT FM

After changing the code... the errors says that INT_ZAHL and UP_ZIFFER are type incompatile

please find the following code which i changed,

in the below coding it is showing error in the following statement

DO 15 TIMES VARYING up_ziffer FROM int_zahl0 NEXT int_zahl1

In SPELL_AMOUNT function modue contains this ZIFFERN_IN_WORTEN subroutine

Thanks in advance.

Jeyanthi.

4 REPLIES 4

Former Member
0 Kudos

Hi ,

May be ur system is Unicode enabaled so offset is not happening

tell me how are int_zahl and UP_ZIFFER DECLARED now and what were earlier declaration.

0 Kudos

Dear Dinesh,

previously the variable declaration was

up_ziffer(1) TYPE c,

in correction i have changed like

up_ziffer(1) TYPE n,

there is no correction with int_zahl.

previousely that do statement was

DO 15 TIMES

then changed as per correction in the notes

like below

DO 15 TIMES VARYING up_ziffer FROM int_zahl0 NEXT int_zahl1.

Thanks.

Jeyanthi

Former Member
0 Kudos

Hi Jeyanthi,

as u told that you have changed type of up_ziffer from c to n .

but int_zahl is of data type c.

so change the data type of either variable n try to execute.

hope this will solve your query.

Thanks & regards

Rajesh Kumar

0 Kudos

no ya...

i have tried it was not working out.....

my system is unicode enabled