Application Development and Automation 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: 
Read only

UC_OBJECTS_NOT_CHARLIKE

Former Member
0 Likes
960

Hi,

I am getting a Dump & the message is " UC_OBJECTS_NOT_CHARLIKE "... I am writing the below code...

  • Internal table to store the output.

DATA : BEGIN OF T_OUTPUT OCCURS 0,

REFDOCNR LIKE GLPCA-REFDOCNR,

SGTXT LIKE GLPCA-SGTXT,

POPER LIKE GLPCA-POPER,

RYEAR LIKE GLPCA-RYEAR,

BLDAT LIKE GLPCA-BLDAT,

BUDAT LIKE GLPCA-BUDAT,

USNAM LIKE GLPCA-USNAM,

PPNAM LIKE BKPF-PPNAM,

REFDOCLN LIKE GLPCA-REFDOCLN,

RBUKRS LIKE GLPCA-RBUKRS,

RPRCTR LIKE GLPCA-RPRCTR,

RACCT LIKE GLPCA-RACCT,

TXT50 LIKE T003T-LTEXT,

DRCRK LIKE GLPCA-DRCRK,

WAERS LIKE T001-WAERS,

HSL LIKE GLPCA-HSL,

CURR2 LIKE T882-CURR2,

KSL LIKE GLPCA-KSL,

BLART LIKE GLPCA-BLART,

LTEXT LIKE SKAT-TXT50,

END OF T_OUTPUT.

FORM SAVE_FILE .

CONCATENATE P_FNAME S_RBUKRS-LOW S_POPER-LOW INTO V_FILENAM

SEPARATED BY '_'.

concatenate v_filenam '.txt' into v_filepath.

IF RB_SAVE = 'X'.

IF NOT T_OUTPUT[] IS INITIAL.

  • Transfer the changed T_INPUTFILE data to application server.

OPEN DATASET V_FILEPATH FOR OUTPUT IN TEXT MODE ENCODING DEFAULT

MESSAGE V_MSG.

IF SY-SUBRC <> 0.

MESSAGE I008. " File could not be opened.

EXIT.

ENDIF.

  • Transferring Data

LOOP AT T_OUTPUT.

TRANSFER T_OUTPUT TO V_FILEPATH. (Dump is occuring here)

ENDLOOP.

CLOSE DATASET V_FILEPATH.

ENDIF.

ENDIF.

ENDFORM.

Could anyone please tell me what is wrong here ??

Thank You,

SB.

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
625

Hi,

Declare the fields in your internal table as characater data type fields and then try to do transfer ..

Thanks,

Naren

1 REPLY 1
Read only

Former Member
0 Likes
626

Hi,

Declare the fields in your internal table as characater data type fields and then try to do transfer ..

Thanks,

Naren