07-05-2008 6:36 PM
hello experts..
I have used gui_upload module to upload the data from flatfile to the internal table, in that how can i create search path for the file selection in the selection screen, also please help me the code to update the ztable.
thanks
07-06-2008 6:00 PM
Hi Gopal,
Check out this thread...
Check out this function module it will help you to find the path for both Application and also Presentation servers..
F4_DXFILENAME_TOPRECURSION.
Check the below program which include even this function module and also some other F4 function modules..
http://www.sapnet.ru/viewtopic.php?p=482&sid=144935daf959d9ca80a5b3b2b0802fa4
Hope the information provided would be helpful and would solve your issue.
Regards
Narin Nandivada
07-05-2008 6:44 PM
HI
If iam not wrong you want to select a file from a location that you don't know so if this is ur problem then use the function module
F4_FILENAME
this FM helps to locate and select the desired file from the system.
Sample code that you can check is
How to get windows filename
PARAMETERS: lv_file LIKE rlgrap-filename.
Method 1
CALL FUNCTION u2019KD_GET_FILENAME_ON_F4u2019
EXPORTING
MASK = u2019,.txt,.*u2019
STATIC = u2019Xu2019
CHANGING
FILE_NAME = LV_FILE.
Method 2
CALL FUNCTION u2019F4_FILENAMEu2019
EXPORTING
program_name = syst-cprog
dynpro_number = syst-dynnr
field_name = u2019 u2019
IMPORTING
file_name = LV_FILE.
Regards
Pavan
07-06-2008 6:00 PM
Hi Gopal,
Check out this thread...
Check out this function module it will help you to find the path for both Application and also Presentation servers..
F4_DXFILENAME_TOPRECURSION.
Check the below program which include even this function module and also some other F4 function modules..
http://www.sapnet.ru/viewtopic.php?p=482&sid=144935daf959d9ca80a5b3b2b0802fa4
Hope the information provided would be helpful and would solve your issue.
Regards
Narin Nandivada
07-06-2008 9:23 PM
Hello Gopal
Define the selection-screen event
AT SELECTION-SCREEN ON VALUE-REQUEST for <parameter_for_file>
When the event is triggered call the static method CL_GUI_FRONTEND_SERVICES=>FILE_OPEN_DIALOG.
Regards
Uwe
07-07-2008 4:55 AM
hi,....
for search path for file on your local pc you can use the following...
*AT SELECTION-SCREEN ON VALUE-REQUEST FOR p_file .
CALL FUNCTION 'F4_FILENAME'
EXPORTING
program_name = syst-cprog
dynpro_number = syst-dynnr
field_name = 'C:\'
IMPORTING
file_name = p_file.
on clicking f4 it will display the search path as you want.