<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Browse folder in the application server in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/browse-folder-in-the-application-server/m-p/6553115#M1429966</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;PRE&gt;&lt;CODE&gt;SELECTION-SCREEN BEGIN OF BLOCK 002 WITH FRAME TITLE text-002.
PARAMETERS : p_aps LIKE rlgrap-filename MODIF ID pth .
SELECTION-SCREEN END OF BLOCK 002.
DATA : path_name(150) TYPE c.

AT SELECTION-SCREEN ON VALUE-REQUEST FOR p_aps.

  SUBMIT rs_get_f4_dir_from_applserv AND RETURN.
  IMPORT path_name FROM MEMORY ID 'PATH_NAME_SDL'.
  p_aps = path_name.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;[Retrieve application server file names in F4 help|http://searchsap.techtarget.com/tip/0,289483,sid21_gci943422,00.html]&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;AT SELECTION-SCREEN ON VALUE-REQUEST FOR p_file1.

PERFORM application_server_path.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;*&amp;amp;---------------------------------------------------------------------*

*&amp;amp; Form application_server_path

*&amp;amp;---------------------------------------------------------------------*

FORM application_server_path.

IF p_read = 'X'.

*&amp;amp; Selecting file from server on pressing f4

CALL FUNCTION '/SAPDMC/LSM_F4_SERVER_FILE'

EXPORTING

directory = '.\'

filemask = ' '

IMPORTING

serverfile = p_file1

EXCEPTIONS

canceled_by_user = 1.

ELSE.

MESSAGE 'F4 is only valid for transfering data from Server to PC' TYPE 'S'.

ENDIF.

ENDFORM. " application_server_path&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 26 Jan 2010 22:10:52 GMT</pubDate>
    <dc:creator>former_member156446</dc:creator>
    <dc:date>2010-01-26T22:10:52Z</dc:date>
    <item>
      <title>Browse folder in the application server</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/browse-folder-in-the-application-server/m-p/6553113#M1429964</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi there,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In a program, I need to create an output file, and to save it either in the applictaion server or in the presentation server.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But I want the user to be able to choose the folder where to save it, not the file itself. Browsing the Web I have found a method of a class, the cl_gui_frontend_services=&amp;gt;directory_browse, by means of which I achieved displaying a screen to select a folder in the computer.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But I couldn't find a function module for displaying a screen for the user to choose a folder from the application server.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Sending an 'A' in the parameter i_server in function module F4_DXFILENAME_TOPRECURSION won't work, since the window displayed is to choose a file and not a folder.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks a lot in advance.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Ignacio&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 26 Jan 2010 21:43:05 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/browse-folder-in-the-application-server/m-p/6553113#M1429964</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-01-26T21:43:05Z</dc:date>
    </item>
    <item>
      <title>Re: Browse folder in the application server</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/browse-folder-in-the-application-server/m-p/6553114#M1429965</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Give this a try:&lt;/P&gt;&lt;P&gt;  &lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;data: l_abend_flag type dxxabend,         "FISKROB
        l_path type dxlpath.

  concatenate '/usr/sap/' sy-sysid into l_path.

*-- F4 functionality for filename on Application Server
  call function 'F4_DXFILENAME_TOPRECURSION'
    exporting
      i_location_flag       = 'A'
      i_server              = ' '
      i_path                = l_path
    importing
      o_path                = l_path
      abend_flag            = l_abend_flag
    exceptions
      communication_failure = 1
      system_failure        = 2
      rfc_error             = 3.
  if sy-subrc eq 0.
    p_file_name = l_path.
  endif.
  if l_abend_flag = 'X'.
    exit.
  endif.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;Rob&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 26 Jan 2010 21:52:43 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/browse-folder-in-the-application-server/m-p/6553114#M1429965</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-01-26T21:52:43Z</dc:date>
    </item>
    <item>
      <title>Re: Browse folder in the application server</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/browse-folder-in-the-application-server/m-p/6553115#M1429966</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;PRE&gt;&lt;CODE&gt;SELECTION-SCREEN BEGIN OF BLOCK 002 WITH FRAME TITLE text-002.
PARAMETERS : p_aps LIKE rlgrap-filename MODIF ID pth .
SELECTION-SCREEN END OF BLOCK 002.
DATA : path_name(150) TYPE c.

AT SELECTION-SCREEN ON VALUE-REQUEST FOR p_aps.

  SUBMIT rs_get_f4_dir_from_applserv AND RETURN.
  IMPORT path_name FROM MEMORY ID 'PATH_NAME_SDL'.
  p_aps = path_name.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;[Retrieve application server file names in F4 help|http://searchsap.techtarget.com/tip/0,289483,sid21_gci943422,00.html]&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;AT SELECTION-SCREEN ON VALUE-REQUEST FOR p_file1.

PERFORM application_server_path.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;*&amp;amp;---------------------------------------------------------------------*

*&amp;amp; Form application_server_path

*&amp;amp;---------------------------------------------------------------------*

FORM application_server_path.

IF p_read = 'X'.

*&amp;amp; Selecting file from server on pressing f4

CALL FUNCTION '/SAPDMC/LSM_F4_SERVER_FILE'

EXPORTING

directory = '.\'

filemask = ' '

IMPORTING

serverfile = p_file1

EXCEPTIONS

canceled_by_user = 1.

ELSE.

MESSAGE 'F4 is only valid for transfering data from Server to PC' TYPE 'S'.

ENDIF.

ENDFORM. " application_server_path&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 26 Jan 2010 22:10:52 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/browse-folder-in-the-application-server/m-p/6553115#M1429966</guid>
      <dc:creator>former_member156446</dc:creator>
      <dc:date>2010-01-26T22:10:52Z</dc:date>
    </item>
  </channel>
</rss>

