‎2006 Nov 20 6:23 PM
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.
‎2006 Nov 20 6:45 PM
Hi,
Declare the fields in your internal table as characater data type fields and then try to do transfer ..
Thanks,
Naren
‎2006 Nov 20 6:45 PM
Hi,
Declare the fields in your internal table as characater data type fields and then try to do transfer ..
Thanks,
Naren