‎2005 Aug 31 11:07 PM
Hello folks,
1.what is the the function module for getting the list of files in a directory.
I tried EPS_GET_DIRECTORY_LISING but it didnt return aything.
2.Is there any sap function module for moving files from one unix directory to another??
Thanks,
Naren
‎2005 Sep 01 8:00 AM
<i>what is the the function module for getting the list of files in a directory.
I tried EPS_GET_DIRECTORY_LISING but it didnt return aything.</i>
if its unix directory files, this is the right function, probably you are missing authorization for authority object <b>S_CTS_ADMI</b>
run the FM from se37 and see whether you are getting authorization error.
Please note that the DIR_NAME parameter value is case sensitive.
Regards
Raja
‎2005 Aug 31 11:24 PM
Hi Naren,
This one is supposed to work. I never tried it and let me know if it works for you.
FM: RZL_READ_DIR
And also check out the function group SAL3.
Regards,
Sumant.
‎2005 Sep 01 2:33 AM
1) Func mod - /SAPDMC/SAPLLSMW_AUX_020
2) DATA: BEGIN OF MOVE_COMMAND1,
FILLER1(3) VALUE 'mv ',
MOVE_ONE_DIR(25)
VALUE '/storedoor/upload/gulan1/',
MOVE_ONE_FILE(12),
FILLER2(1) VALUE SPACE,
MOVE_TWO_DIR(30)
VALUE '/storedoor/upload/gulan1/done/',
MOVE_TWO_FILE(12),
END OF MOVE_COMMAND1.
CALL 'SYSTEM' ID 'COMMAND' FIELD MOVE_COMMAND1.
‎2005 Sep 01 6:09 AM
You cal also use SXPG_COMMAND_EXECUTE and define commands under SM49
‎2005 Sep 01 7:37 AM
Hi,
If you want to list the files in a directory of the presentation server, you can use this static method.
CALL METHOD CL_GUI_FRONTEND_SERVICES=>DIRECTORY_LIST_FILES
Use the class browser(se24) to display the parameters.
Svetlin
P.S. If you find an answer helpful, please assign reward points.
‎2005 Sep 01 8:00 AM
<i>what is the the function module for getting the list of files in a directory.
I tried EPS_GET_DIRECTORY_LISING but it didnt return aything.</i>
if its unix directory files, this is the right function, probably you are missing authorization for authority object <b>S_CTS_ADMI</b>
run the FM from se37 and see whether you are getting authorization error.
Please note that the DIR_NAME parameter value is case sensitive.
Regards
Raja