Skip to Content
author's profile photo Former Member
Former Member

FM to select a directory from application server

Hi all,

I need a FM to select a directoroy from application server and the name for the file I am going to create.

It must be something like the FM GUI_FILE_SAVE_DIALOG, but for sap server.

Can anyone help me?

Thanks in Advance.

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

5 Answers

  • Best Answer
    author's profile photo Former Member
    Former Member
    Posted on Nov 22, 2007 at 01:08 PM

    Use the code below:

    PARAMETERS: f_app(128).

    AT SELECTION-SCREEN ON VALUE-REQUEST FOR f_app.

    PERFORM get_fname_app.

    &----


    *& Form get_fname_app

    &----


    • text

    ----


    FORM get_fname_app.

    DATA: c_fnh_mask TYPE dxfields-filemask VALUE '.',

    search_dir TYPE dxfields-longpath VALUE '/sapglobal/users',

    file_path LIKE dxfields-longpath.

    CALL FUNCTION 'F4_DXFILENAME_TOPRECURSION'

    EXPORTING

    i_location_flag = 'A'

    i_server = ' '

    i_path = search_dir

    filemask = c_fnh_mask

    fileoperation = 'R'

    IMPORTING

    o_path = file_path

    EXCEPTIONS

    rfc_error = 1

    OTHERS = 2.

    IF sy-subrc EQ 0.

    f_app = file_path.

    ENDIF.

    ENDFORM. "get_fname_app

    Hope it helps.

    Lokesh

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Nov 22, 2007 at 12:54 PM

    Hi,

    There is no function module available to upload the documents to Application server. You need to use OPEN DATASET.....

    Regards,

    Satish

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Nov 22, 2007 at 12:56 PM

    Hi

    use

    <b>CG3Z</b> transaction to place files on application server from presentation

    or have to use OPEN DATASET, READ and TRANSFER dataset concepts

    Regards

    Anji

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Nov 22, 2007 at 01:01 PM

    Hi ,

    You can use FM F4_DXFILENAME_TOPRECURSION. This FM will provide you with the option to choos apllication server and the corresponding directory. You can try to test it stand alone in SE37 with default parameters and check if it suits your requirement.

    <b>Reward points if useful</b>

    Regards

    Saket Sharma

    null

    null

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Nov 22, 2007 at 03:26 PM

    Hi again,

    Thanks for all the answers.

    Unfortunately, that's not help me, because F4_DXFILENAME_TOPRECURSION, let me choose one file that exist in the system, but I need to choose a directory and the name of a file i am going to create, so this file does not exist in the system.

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.