Execute DOS Command from ABAP
in SAP Version 3.x
* * Execute DOS Command in SAP Version 3.x * * Written by : SAP Basis, ABAP Programming and Other IMG Stuff * http://www.erpgreat.com * REPORT ZDOSCMDSAP3. DATA: BEGIN OF ITAB OCCURS 0, DOSCMD LIKE RLGRAP-FILENAME, END OF ITAB. ITAB-DOSCMD = 'CD\'. APPEND ITAB. ITAB-DOSCMD = 'MD TESTDIR'. APPEND ITAB. CALL FUNCTION 'WS_DOWNLOAD' EXPORTING FILENAME = 'C:\DOSCMD.BAT' FILETYPE = 'DAT' TABLES DATA_TAB = ITAB EXCEPTIONS FILE_OPEN_ERROR = 1 FILE_WRITE_ERROR = 2 INVALID_FILESIZE = 3 INVALID_TYPE = 4 NO_BATCH = 5 UNKNOWN_ERROR = 6 INVALID_TABLE_WIDTH = 7 GUI_REFUSE_FILETRANSFER = 8 CUSTOMER_ERROR = 9 OTHERS = 10. CALL FUNCTION 'WS_EXECUTE' EXPORTING PROGRAM = 'C:\DOSCMD.BAT'. *-- End of Program Read Also
ABAP Books
More ABAP Tips
SAP ERP Modules, Basis, ABAP and Other IMG Stuff All the site contents are Copyright © www.erpgreat.com
and the content authors. All rights reserved.
|