cancel
Showing results for 
Search instead for 
Did you mean: 

Not able to select the Path or choose file Using Abap Code

AadivaramAbbulu
Explorer
0 Kudos
133

HI.
Need some help and suggestions.
There is one Custom Tcode for Z program. One of the functionalities is like Need to select the path from the Desktop, so that program will build one logic and output will be save into the selected location.

In Z-Tcode Once click on the F4, it is working as expected like asking user to choose the directory from the Desktop. But this Z-program is coming Fiori once select the F4. Not able to choose anything.

Please have a look on two views i had attached. I debug the code. from both GUI and Fiori. have not seen any return message from the below Piece of code. May I know why the issue is coming. Any settings need to be change. Please Correct me. and checked with Security team too any authorization missing issue. But they replied like everything is good from their side. Thank U.

AT SELECTION-SCREEN ON VALUE-REQUEST FOR p_fpath.

  CALL METHOD cl_gui_frontend_services=>directory_browse
    CHANGING
      selected_folder      = p_fpath
    EXCEPTIONS
      cntl_error           = 1
      error_no_gui         = 2
      not_supported_by_gui = 3
      OTHERS               = 4.
  IF sy-subrc EQ 0.
    gv_pathname = p_fpath.
    WRITE: gv_pathname.
  ENDIF.

 

 

Accepted Solutions (0)

Answers (1)

Answers (1)

Dinu
Active Contributor

This is the behavior of Web GUI aka SAP GUI for HTML.

Please refer to sap note 2249454 - ITS Up/Down: Using the WEBGUI File Browser