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: 

Problem in BAPI_FIXEDASSET_CHANGE

Former Member
0 Kudos

Hi guys,

I am trying to use BAPI_FIXEDASSET_CHANGE bapi, but it is giving as error - that assetr does not exist for company code.

But asset actually present in system for that company code.

What can be the problem.

Kindly help.

CALL FUNCTION 'BAPI_FIXEDASSET_CHANGE'

EXPORTING

companycode = p_bukrs

asset = it_infile-anln1

subnumber = it_infile-anln2

generaldata = l_generaldata

generaldatax = l_generaldatax

inventory = l_inventory

inventoryx = l_inventoryx

postinginformation = l_postinginfo

postinginformationx = l_postinginfox

timedependentdata = l_timedependata

timedependentdatax = l_timedependatax

origin = l_origin

originx = l_originx

leasing = l_leasing

leasingx = l_leasingx

IMPORTING

return = l_return

Value of sy-subrc is 0 but it returns l_return-type = 'E'

Kindly help.

thx in advance.

1 ACCEPTED SOLUTION

Clemenss
Active Contributor
0 Kudos

Hi kiran,

the data element ANLN1 is connected with domain ANLN1. This is a CHAR field with 12 characters connected to conversion exit ALPHA. That means that numbers will get preceding leading zeroes for the internal storage and use. The BAPI expects the number to be in internal format.

You may call

CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
  EXPORTING
    input         = it_infile-anln1
  IMPORTING
    OUTPUT        = it_infile-anln1
          .

(and also for ANLN2) before calling the BAPI.

Note: A BAPI will almost always return SY-SUBRC = 0 which means technically everything worked. Errors are always reported in RETURN parameter - for some BAPIs a table storing all errors that have been recorded.

Kind regards,

Clemens

2 REPLIES 2

Clemenss
Active Contributor
0 Kudos

Hi kiran,

the data element ANLN1 is connected with domain ANLN1. This is a CHAR field with 12 characters connected to conversion exit ALPHA. That means that numbers will get preceding leading zeroes for the internal storage and use. The BAPI expects the number to be in internal format.

You may call

CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
  EXPORTING
    input         = it_infile-anln1
  IMPORTING
    OUTPUT        = it_infile-anln1
          .

(and also for ANLN2) before calling the BAPI.

Note: A BAPI will almost always return SY-SUBRC = 0 which means technically everything worked. Errors are always reported in RETURN parameter - for some BAPIs a table storing all errors that have been recorded.

Kind regards,

Clemens

Former Member
0 Kudos

My problem is solved.

Thx a lot.