2005 Oct 14 7:23 AM
hai frnds,
i am having requirement in which i have to accept the file path of application server. i am using the func
f4_filename_server. but when i am selecting the filename the value is not returned in the input box...can anyone help me in this.
Message was edited by: Ateeq K
hai frnds,
i am having requirement in which i have to accept the file path of application server. i am using the func
f4_filename_server. but when i am selecting the filename the value is not returned in the input box...can anyone help me in this.
Message was edited by: Ateeq K
2005 Oct 14 7:32 AM
hi,
you write in the event
AT SELECTION-SCREEN ON VALUE-REQUEST FOR p_infile.
cheers,
sasi
2005 Oct 14 7:41 AM
form get_data.
CALL FUNCTION 'F4_FILENAME_SERVER'
EXPORTING
PFAD = '/sapglobal/users/sdmgr/'
IMPORTING
FILE_NAME = p_file
EXCEPTIONS
NO_FILE_ON_SERVER = 1
OTHERS = 2
.
endform.
Message was edited by: Hashmatullah
2005 Oct 14 7:39 AM
Hi,
Check this sample code from Standard program.
PROCESS ON VALUE-REQUEST.
FIELD IBIPPARMS-PATH MODULE HELP_PATH.
MODULE help_path INPUT.
PERFORM buttons_pressed.
IF ibipparms-pc = 'X'.
CALL FUNCTION 'F4_FILENAME'
EXPORTING
field_name = 'IBIPPARMS-PATH'
IMPORTING
file_name = ibipparms-path.
ELSEIF ibipparms-unix = 'X'.
CALL FUNCTION 'F4_FILENAME_SERVER' DESTINATION ibipparms-server
EXPORTING
pfad = ibipparms-path
IMPORTING
FILE_NAME =
EXCEPTIONS
no_file_on_server = 1
OTHERS = 2.
ENDIF.
ENDMODULE. " HELP_PATH INPUT
Kindly reward points by clicking the star on the left of reply,if it helps.
2005 Oct 14 10:53 AM
is it possible to select the files in the application server through the fm f4_filename....?
`
2005 Oct 14 11:03 AM
F4_FILENAME is not for applivation server . It is for selecting file on your PC.
Try this should work.
PARAMETERS FILE LIKE RLGRAP-FILENAME.
AT SELECTION-SCREEN ON VALUE-REQUEST FOR FILE.
CALL FUNCTION 'F4_FILENAME'
EXPORTING
PROGRAM_NAME = SYST-CPROG
DYNPRO_NUMBER = SYST-DYNNR
FIELD_NAME = ' '
IMPORTING
FILE_NAME = FILE
.
If you want to select server file see my post here -
Cheers
2005 Oct 14 11:15 AM
Hi ateeq,
try this....
data : FILE LIKE RLGRAP-FILENAME.
AT SELECTION-SCREEN ON VALUE-REQUEST FOR FILE.
CALL FUNCTION 'KD_GET_FILENAME_ON_F4'
EXPORTING
MASK = '*.csv;*.prn'
STATIC = 'X'
CHANGING
FILE_NAME = FILE.regards,
venu.
2005 Oct 14 8:36 AM
Hi,
Try this,
*Selecting a File, plus inserting default file extension
parameters: p_file like rlgrap-filename default 'c:\hesa.txt' LOWER CASE.
AT SELECTION-SCREEN ON VALUE-REQUEST FOR i_file.
CALL FUNCTION 'FILENAME_GET'
EXPORTING
def_filename = p_file
mask = ',*.xls.'
mode = 'O'
title = 'Upload File'(078)
IMPORTING
filename = p_file
EXCEPTIONS
inv_winsys = 1
no_batch = 2
selection_cancel = 3
selection_error = 4
OTHERS = 5.
Hope it helps u.
Thanks&Regards,
Ruthra