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: 

BAPI_OBJCL_CREATE

Former Member
0 Kudos

Hello all,

I getting some errors when I trying to use this BAPI.

The fields will be filled by an excel file:

OBJEK / OBJTYPE / KLART / CLASS / DESIGNATION_COURT / GPE_MARCHANDISES

1754490 / Mat / 001 / M001 / DLE10 - Chargement Txt Cde / 0102

DIVISION_ARTICLE / MATIERE / CONSTRUCTEUR / CDF_ATELIER / DCF

0273 / TEST / XYZ / 02 / DCF

into the program, I am coding:


DATA: t_char LIKE bapi1003_alloc_values_char OCCURS 0 WITH HEADER LINE,
      t_num  like BAPI1003_ALLOC_VALUES_NUM OCCURS 0 WITH HEADER LINE,
      t_curr like BAPI1003_ALLOC_VALUES_CURR OCCURS 0 WITH HEADER LINE,
      t_retur LIKE bapiret2 OCCURS 0 WITH HEADER LINE.

DATA: status TYPE bapi1003_key-status.


t_char-charact = 'DESIGNATION_COURTE'.
t_char-value_char = 'DLE10 - Chargement Txt Cde'.

t_char-charact = 'GPE_MARCHANDISES'.
t_char-value_char = '0102'.

t_char-charact = 'DIVISION_ARTICLE'.
t_char-value_char = '0273'.

t_char-charact = 'MATIERE	CONSTRUCTEUR'.
t_char-value_char = 'TEST'.

t_char-charact = 'REF_CONSTRUCTEUR'.
t_char-value_char = 'XYZ'.

t_char-charact = 'CDF_ATELIER'.
t_char-value_char = '02'.

t_char-charact = 'DCF'.
t_char-value_char = 'DCF'.

t_char-charact = 'DIVISION_ARTICLE'.
t_char-value_char = '7852'.

APPEND t_char.

CALL FUNCTION 'BAPI_OBJCL_CREATE'
  EXPORTING
    objectkeynew            = 'TEST'
    objecttablenew          = 'MARA'
    classnumnew             = 'M001'
    classtypenew            = '001'
   status                  = '1'
*   STANDARDCLASS           =
*   CHANGENUMBER            =
   KEYDATE                 = SY-DATUM
*   NO_DEFAULT_VALUES       = ' '
 IMPORTING
   classif_status          = status
  TABLES
*   ALLOCVALUESNUM          =
   allocvalueschar         = t_char
*   ALLOCVALUESCURR         =
    return                  = t_retur.

After executing this BAPI, I got this message at table t_retur:

Assignment does not exist or is not valid on

5 REPLIES 5

Former Member
0 Kudos

I solved this problem.

0 Kudos

How did you solve this problem?

0 Kudos

Yeas please, how have you solved this problem? Thanks

0 Kudos

Hi rimeira ,

Could you please let me know how you resolved the issue. I am also facing the similar error message.

Thanks,

Vinoth

0 Kudos

Please let me know how did u solved this problem?

Thanks in advance.