Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

browse directory in application server

former_member220801
Participant
0 Kudos

I would like to ask if there is any FM provide similar result to that of CL_GUI_FRONTEND_SERVICES=>DIRECTORY_BROWSE

but browsing the directories in application server?

I want to open a browse directory dialog for input and return the directory path only (doesn't include file name).

Thanks!

1 ACCEPTED SOLUTION

former_member927251
Active Contributor
0 Kudos

Hi Gundam,

Use the following code :

AT SELECTION-SCREEN ON VALUE-REQUEST FOR p_apath.

  • Open the Browse Dialog Box on the Application Server

CALL FUNCTION '/SAPDMC/LSM_F4_SERVER_FILE'

IMPORTING

serverfile = p_apath

EXCEPTIONS

canceled_by_user = 1

OTHERS = 2.

IF sy-subrc <> 0.

  • No need to check for sy-subrc

ENDIF.

<b>Please mark helpful answer.</b>

Regards,

Amit Mishra

5 REPLIES 5

hymavathi_oruganti
Active Contributor
0 Kudos

F4_FILENAME_SERVER

example:

parameter: p type i.

data file type IBIPPARMS-PATH.

at selection-screen on value-request for p.

CALL FUNCTION 'F4_FILENAME_SERVER'

EXPORTING

PFAD = file.

Message was edited by: Hymavathi Oruganti

Former Member
0 Kudos

Hi gundam,

1. F4_DXFILENAME_TOPRECURSION

regards,

amit m.

vinod_gunaware2
Active Contributor
0 Kudos

F4_DXFILENAME_TOPRECURSION

Popup to select one file from the given application server directory (pattern allowed). (Can be used also for selecting file on presentation server: calls WS_FILENAME_GET)

Parameters: I_LOCATION_FLAG={A|P|space}; if I_LOCATION_FLAG is blank then popup to choose Appl./Present.; if I_SERVER='?' then popup to select appl.server.

regards

vinod

Former Member
0 Kudos

Hi,

You can use /SAPDMC/LSM_F4_SERVER_FILE FM. It will work for both u can select up to path or file also.

rajkumar abbu

former_member927251
Active Contributor
0 Kudos

Hi Gundam,

Use the following code :

AT SELECTION-SCREEN ON VALUE-REQUEST FOR p_apath.

  • Open the Browse Dialog Box on the Application Server

CALL FUNCTION '/SAPDMC/LSM_F4_SERVER_FILE'

IMPORTING

serverfile = p_apath

EXCEPTIONS

canceled_by_user = 1

OTHERS = 2.

IF sy-subrc <> 0.

  • No need to check for sy-subrc

ENDIF.

<b>Please mark helpful answer.</b>

Regards,

Amit Mishra