Select several files in open dialog.
In a program, I used one input file selected by this function 'AL_POPUP_FOR_LOCAL_PATH' (open dialog) but now, I must several files same times.
I used the input file for splitting in three files in output. Now, I must to split several files always in three files in output.
The way is same for this two process or for several files, it's necessary to proced of another way?
Hi Xavier Couloumies,
Try below code...
Press F4 for the text box...
then select multiple files by pressing control button...
then See the button with ==> near to the textbox which is for multiple selection... press it and u can see all selected files there... now u can use it as per your logic...
TABLES: FILE_TABLE. DATA: LT_FILE_NAMES TYPE FILETABLE, LWA_FILE_NAME TYPE FILE_TABLE, LV_SUBRC TYPE I. SELECT-OPTIONS: MUL_FILE FOR FILE_TABLE NO INTERVALS. AT SELECTION-SCREEN ON VALUE-REQUEST FOR MUL_FILE-LOW. CALL METHOD CL_GUI_FRONTEND_SERVICES=>FILE_OPEN_DIALOG EXPORTING * WINDOW_TITLE = * DEFAULT_EXTENSION = * DEFAULT_FILENAME = * FILE_FILTER = INITIAL_DIRECTORY = 'C:Temp' MULTISELECTION = 'X' CHANGING FILE_TABLE = LT_FILE_NAMES RC = LV_SUBRC * USER_ACTION = EXCEPTIONS FILE_OPEN_DIALOG_FAILED = 1 CNTL_ERROR = 2 ERROR_NO_GUI = 3 OTHERS = 4. IF SY-SUBRC <> 0. * MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO * WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4. ENDIF. MUL_FILE-SIGN = 'I'. MUL_FILE-OPTION = 'EQ'. LOOP AT LT_FILE_NAMES INTO LWA_FILE_NAME. MUL_FILE-LOW = LWA_FILE_NAME. APPEND MUL_FILE. ENDLOOP. START-OF-SELECTION. LOOP AT MUL_FILE. WRITE: / MUL_FILE-LOW. ENDLOOP.
Hope it will solve your problem..
Thanks & Regards