<?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: Selection Screen in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/selection-screen/m-p/2900970#M682177</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;To upload file from presentation server, here is the code -&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;parameters: p_file type localfile.&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;at selection-screen on value-request for p_file.&lt;/P&gt;&lt;P&gt;  call function 'KD_GET_FILENAME_ON_F4'&lt;/P&gt;&lt;P&gt;       exporting&lt;/P&gt;&lt;P&gt;            static    = 'X'&lt;/P&gt;&lt;P&gt;       changing&lt;/P&gt;&lt;P&gt;            file_name = p_file.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;start-of-selection.&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;  file_str = p_file.&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;  call function 'GUI_UPLOAD'&lt;/P&gt;&lt;P&gt;       exporting&lt;/P&gt;&lt;P&gt;            filename                = file_str&lt;/P&gt;&lt;P&gt;       tables&lt;/P&gt;&lt;P&gt;            data_tab                = itab&lt;/P&gt;&lt;P&gt;       exceptions&lt;/P&gt;&lt;P&gt;            file_open_error         = 1&lt;/P&gt;&lt;P&gt;            file_read_error         = 2&lt;/P&gt;&lt;P&gt;            no_batch                = 3&lt;/P&gt;&lt;P&gt;            gui_refuse_filetransfer = 4&lt;/P&gt;&lt;P&gt;            invalid_type            = 5&lt;/P&gt;&lt;P&gt;            no_authority            = 6&lt;/P&gt;&lt;P&gt;            unknown_error           = 7&lt;/P&gt;&lt;P&gt;            bad_data_format         = 8&lt;/P&gt;&lt;P&gt;            header_not_allowed      = 9&lt;/P&gt;&lt;P&gt;            separator_not_allowed   = 10&lt;/P&gt;&lt;P&gt;            header_too_long         = 11&lt;/P&gt;&lt;P&gt;            unknown_dp_error        = 12&lt;/P&gt;&lt;P&gt;            access_denied           = 13&lt;/P&gt;&lt;P&gt;            dp_out_of_memory        = 14&lt;/P&gt;&lt;P&gt;            disk_full               = 15&lt;/P&gt;&lt;P&gt;            dp_timeout              = 16&lt;/P&gt;&lt;P&gt;            others                  = 17.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;To upload file from application server, here is the code -&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;REPORT  zuploadtab                    .&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;PARAMETERS: p_infile  LIKE rlgrap-filename&lt;/P&gt;&lt;P&gt;OBLIGATORY DEFAULT  &amp;#145;/usr/sap/&amp;#146;..&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;DATA: ld_file LIKE rlgrap-filename.&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;*Internal tabe to store upload data&lt;/P&gt;&lt;P&gt;TYPES: BEGIN OF t_record,&lt;/P&gt;&lt;P&gt;name1 like pa0002-VORNA,&lt;/P&gt;&lt;P&gt;name2 like pa0002-name2,&lt;/P&gt;&lt;P&gt;age   type i,&lt;/P&gt;&lt;P&gt;END OF t_record.&lt;/P&gt;&lt;P&gt;DATA: it_record TYPE STANDARD TABLE OF t_record INITIAL SIZE 0,&lt;/P&gt;&lt;P&gt;wa_record TYPE t_record.&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;*Text version of data table&lt;/P&gt;&lt;P&gt;TYPES: begin of t_uploadtxt,&lt;/P&gt;&lt;P&gt;name1(10) type c,&lt;/P&gt;&lt;P&gt;name2(15) type c,&lt;/P&gt;&lt;P&gt;age(5)  type c,&lt;/P&gt;&lt;P&gt;end of t_uploadtxt.&lt;/P&gt;&lt;P&gt;DATA: wa_uploadtxt TYPE t_uploadtxt.&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;*String value to data in initially.&lt;/P&gt;&lt;P&gt;DATA: wa_string(255) type c.&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;constants: con_tab TYPE x VALUE &amp;#145;09&amp;amp;#8242;.&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;*START-OF-SELECTION&lt;/P&gt;&lt;P&gt;START-OF-SELECTION.&lt;/P&gt;&lt;P&gt;ld_file = p_infile.&lt;/P&gt;&lt;P&gt;OPEN DATASET ld_file FOR INPUT IN TEXT MODE ENCODING DEFAULT.&lt;/P&gt;&lt;P&gt;IF sy-subrc NE 0.&lt;/P&gt;&lt;P&gt;ELSE.&lt;/P&gt;&lt;P&gt;DO.&lt;/P&gt;&lt;P&gt;CLEAR: wa_string, wa_uploadtxt.&lt;/P&gt;&lt;P&gt;READ DATASET ld_file INTO wa_string.&lt;/P&gt;&lt;P&gt;IF sy-subrc NE 0.&lt;/P&gt;&lt;P&gt;EXIT.&lt;/P&gt;&lt;P&gt;ELSE.&lt;/P&gt;&lt;P&gt;SPLIT wa_string AT con_tab INTO wa_uploadtxt-name1&lt;/P&gt;&lt;P&gt;wa_uploadtxt-name2&lt;/P&gt;&lt;P&gt;wa_uploadtxt-age.&lt;/P&gt;&lt;P&gt;MOVE-CORRESPONDING wa_uploadtxt TO wa_upload.&lt;/P&gt;&lt;P&gt;APPEND wa_upload TO it_record.&lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;P&gt;ENDDO.&lt;/P&gt;&lt;P&gt;CLOSE DATASET ld_file.&lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You need to change your internal table structure as per your file format.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You also need to combine these code samples as per your requirement in your program.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this helps.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ashish&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 08 Oct 2007 15:16:38 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2007-10-08T15:16:38Z</dc:date>
    <item>
      <title>Selection Screen</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/selection-screen/m-p/2900969#M682176</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi gurus, &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have a condition where I need to upload the file to my program, the file may either come from the system or from the application server, so basically I need to ask user from which way it is coming and then if the user entered that its coming from the computer then I need to ask him the location of the file and same as in the case if user selects applications server, &lt;/P&gt;&lt;P&gt;So far what I know is that first we need to use the radio buttons to ask the user to select either of the option and then as per his selection we need him to enter the file location. For this I tried the below code and this code allows me to select either of the option and now I have two more concerns, as soon as I select the radio button which says that file is coming from the server I should ask the user to enter the file location. I believe this could achieve by using  CALL FUNCTION 'F4_FILENAME' and once he selected the file location then I need to upload that file using the function module WS_UPLOAD, so can you please tell me how to get this thing done.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;REPORT  Z_TEST1  .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*--- Radiobuttons&lt;/P&gt;&lt;P&gt;PARAMETERS: p_up RADIOBUTTON GROUP a DEFAULT 'X' USER-COMMAND rb,&lt;/P&gt;&lt;P&gt;            p_list RADIOBUTTON GROUP a.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;PARAMETERS: p_pcfile LIKE rlgrap-filename OBLIGATORY&lt;/P&gt;&lt;P&gt;MODIF ID ccc.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Parameters: p_unix LIKE rlgrap-filename OBLIGATORY DEFAULT '.\'&lt;/P&gt;&lt;P&gt;MODIF ID ddd.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*----&lt;/P&gt;&lt;HR originaltext="----------------------------------------------------------------" /&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;AT SELECTION-SCREEN&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;*----&lt;/P&gt;&lt;HR originaltext="----------------------------------------------------------------" /&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;AT SELECTION-SCREEN OUTPUT.&lt;/P&gt;&lt;P&gt;  IF p_up = 'X' .&lt;/P&gt;&lt;P&gt;    LOOP AT SCREEN.&lt;/P&gt;&lt;P&gt;      CASE screen-group1.&lt;/P&gt;&lt;P&gt;        WHEN 'CCC'.&lt;/P&gt;&lt;P&gt;          screen-input = 1. "Enable&lt;/P&gt;&lt;P&gt;          screen-invisible = 0. "Disable&lt;/P&gt;&lt;P&gt;          MODIFY SCREEN.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;        WHEN 'DDD'.&lt;/P&gt;&lt;P&gt;          screen-input = 0.&lt;/P&gt;&lt;P&gt;          screen-invisible = 1.&lt;/P&gt;&lt;P&gt;          MODIFY SCREEN.&lt;/P&gt;&lt;P&gt;      ENDCASE.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;   CALL FUNCTION 'F4_FILENAME'                       "allows user to select path/file&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;     EXPORTING&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;        program_name  = 'ZMMINT_PO_CONVERSION'&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;        dynpro_number = syst-dynnr&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;        field_name    =  'p_up'&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;     IMPORTING&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;       file_name     = p_up.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;    ENDLOOP.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  ENDIF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  IF p_list = 'X'.&lt;/P&gt;&lt;P&gt;    LOOP AT SCREEN.&lt;/P&gt;&lt;P&gt;      CASE screen-group1.&lt;/P&gt;&lt;P&gt;        WHEN 'CCC'.&lt;/P&gt;&lt;P&gt;          screen-input = 0.&lt;/P&gt;&lt;P&gt;          screen-invisible = 1.&lt;/P&gt;&lt;P&gt;          MODIFY SCREEN.&lt;/P&gt;&lt;P&gt;        WHEN 'DDD'.&lt;/P&gt;&lt;P&gt;          screen-input = 1.&lt;/P&gt;&lt;P&gt;          screen-invisible = 0.&lt;/P&gt;&lt;P&gt;          MODIFY SCREEN.&lt;/P&gt;&lt;P&gt;      ENDCASE.&lt;/P&gt;&lt;P&gt;    ENDLOOP.&lt;/P&gt;&lt;P&gt;  ENDIF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks in advance &lt;/P&gt;&lt;P&gt;Rajeev Gupta&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Message was edited by: &lt;/P&gt;&lt;P&gt;        Rajeev Gupta&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 08 Oct 2007 15:11:06 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/selection-screen/m-p/2900969#M682176</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-10-08T15:11:06Z</dc:date>
    </item>
    <item>
      <title>Re: Selection Screen</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/selection-screen/m-p/2900970#M682177</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;To upload file from presentation server, here is the code -&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;parameters: p_file type localfile.&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;at selection-screen on value-request for p_file.&lt;/P&gt;&lt;P&gt;  call function 'KD_GET_FILENAME_ON_F4'&lt;/P&gt;&lt;P&gt;       exporting&lt;/P&gt;&lt;P&gt;            static    = 'X'&lt;/P&gt;&lt;P&gt;       changing&lt;/P&gt;&lt;P&gt;            file_name = p_file.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;start-of-selection.&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;  file_str = p_file.&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;  call function 'GUI_UPLOAD'&lt;/P&gt;&lt;P&gt;       exporting&lt;/P&gt;&lt;P&gt;            filename                = file_str&lt;/P&gt;&lt;P&gt;       tables&lt;/P&gt;&lt;P&gt;            data_tab                = itab&lt;/P&gt;&lt;P&gt;       exceptions&lt;/P&gt;&lt;P&gt;            file_open_error         = 1&lt;/P&gt;&lt;P&gt;            file_read_error         = 2&lt;/P&gt;&lt;P&gt;            no_batch                = 3&lt;/P&gt;&lt;P&gt;            gui_refuse_filetransfer = 4&lt;/P&gt;&lt;P&gt;            invalid_type            = 5&lt;/P&gt;&lt;P&gt;            no_authority            = 6&lt;/P&gt;&lt;P&gt;            unknown_error           = 7&lt;/P&gt;&lt;P&gt;            bad_data_format         = 8&lt;/P&gt;&lt;P&gt;            header_not_allowed      = 9&lt;/P&gt;&lt;P&gt;            separator_not_allowed   = 10&lt;/P&gt;&lt;P&gt;            header_too_long         = 11&lt;/P&gt;&lt;P&gt;            unknown_dp_error        = 12&lt;/P&gt;&lt;P&gt;            access_denied           = 13&lt;/P&gt;&lt;P&gt;            dp_out_of_memory        = 14&lt;/P&gt;&lt;P&gt;            disk_full               = 15&lt;/P&gt;&lt;P&gt;            dp_timeout              = 16&lt;/P&gt;&lt;P&gt;            others                  = 17.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;To upload file from application server, here is the code -&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;REPORT  zuploadtab                    .&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;PARAMETERS: p_infile  LIKE rlgrap-filename&lt;/P&gt;&lt;P&gt;OBLIGATORY DEFAULT  &amp;#145;/usr/sap/&amp;#146;..&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;DATA: ld_file LIKE rlgrap-filename.&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;*Internal tabe to store upload data&lt;/P&gt;&lt;P&gt;TYPES: BEGIN OF t_record,&lt;/P&gt;&lt;P&gt;name1 like pa0002-VORNA,&lt;/P&gt;&lt;P&gt;name2 like pa0002-name2,&lt;/P&gt;&lt;P&gt;age   type i,&lt;/P&gt;&lt;P&gt;END OF t_record.&lt;/P&gt;&lt;P&gt;DATA: it_record TYPE STANDARD TABLE OF t_record INITIAL SIZE 0,&lt;/P&gt;&lt;P&gt;wa_record TYPE t_record.&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;*Text version of data table&lt;/P&gt;&lt;P&gt;TYPES: begin of t_uploadtxt,&lt;/P&gt;&lt;P&gt;name1(10) type c,&lt;/P&gt;&lt;P&gt;name2(15) type c,&lt;/P&gt;&lt;P&gt;age(5)  type c,&lt;/P&gt;&lt;P&gt;end of t_uploadtxt.&lt;/P&gt;&lt;P&gt;DATA: wa_uploadtxt TYPE t_uploadtxt.&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;*String value to data in initially.&lt;/P&gt;&lt;P&gt;DATA: wa_string(255) type c.&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;constants: con_tab TYPE x VALUE &amp;#145;09&amp;amp;#8242;.&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;*START-OF-SELECTION&lt;/P&gt;&lt;P&gt;START-OF-SELECTION.&lt;/P&gt;&lt;P&gt;ld_file = p_infile.&lt;/P&gt;&lt;P&gt;OPEN DATASET ld_file FOR INPUT IN TEXT MODE ENCODING DEFAULT.&lt;/P&gt;&lt;P&gt;IF sy-subrc NE 0.&lt;/P&gt;&lt;P&gt;ELSE.&lt;/P&gt;&lt;P&gt;DO.&lt;/P&gt;&lt;P&gt;CLEAR: wa_string, wa_uploadtxt.&lt;/P&gt;&lt;P&gt;READ DATASET ld_file INTO wa_string.&lt;/P&gt;&lt;P&gt;IF sy-subrc NE 0.&lt;/P&gt;&lt;P&gt;EXIT.&lt;/P&gt;&lt;P&gt;ELSE.&lt;/P&gt;&lt;P&gt;SPLIT wa_string AT con_tab INTO wa_uploadtxt-name1&lt;/P&gt;&lt;P&gt;wa_uploadtxt-name2&lt;/P&gt;&lt;P&gt;wa_uploadtxt-age.&lt;/P&gt;&lt;P&gt;MOVE-CORRESPONDING wa_uploadtxt TO wa_upload.&lt;/P&gt;&lt;P&gt;APPEND wa_upload TO it_record.&lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;P&gt;ENDDO.&lt;/P&gt;&lt;P&gt;CLOSE DATASET ld_file.&lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You need to change your internal table structure as per your file format.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You also need to combine these code samples as per your requirement in your program.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this helps.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ashish&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 08 Oct 2007 15:16:38 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/selection-screen/m-p/2900970#M682177</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-10-08T15:16:38Z</dc:date>
    </item>
    <item>
      <title>Re: Selection Screen</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/selection-screen/m-p/2900971#M682178</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;Ur code is fine.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;use&lt;/P&gt;&lt;P&gt; at selection-screen on value-request for p_file.&lt;/P&gt;&lt;P&gt;call function 'KD_GET_FILENAME_ON_F4'&lt;/P&gt;&lt;P&gt;start of selection.&lt;/P&gt;&lt;P&gt;if presentaion server is selected.&lt;/P&gt;&lt;P&gt;GUI_UPLOAD.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;How ever u cant do F4 for app server. For that you can default the values for the parameters in initialisation event as below&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;initialisation.&lt;/P&gt;&lt;P&gt;p_file = 'SAP\USR\test.txt'&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 08 Oct 2007 15:23:44 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/selection-screen/m-p/2900971#M682178</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-10-08T15:23:44Z</dc:date>
    </item>
    <item>
      <title>Re: Selection Screen</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/selection-screen/m-p/2900972#M682179</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hey sreejith , first of all thanks for the reply, &lt;/P&gt;&lt;P&gt;Well as of now I have written the following code:&lt;/P&gt;&lt;P&gt;REPORT  Z_TEST1  .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*--- Radiobuttons&lt;/P&gt;&lt;P&gt;PARAMETERS: p_up RADIOBUTTON GROUP a DEFAULT 'X' USER-COMMAND rb,&lt;/P&gt;&lt;P&gt;            p_list RADIOBUTTON GROUP a.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;PARAMETERS: p_pcfile LIKE rlgrap-filename OBLIGATORY&lt;/P&gt;&lt;P&gt;MODIF ID CCC.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Parameters: p_unix LIKE rlgrap-filename OBLIGATORY DEFAULT '.\tmp'&lt;/P&gt;&lt;P&gt;MODIF ID DDD.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*----&lt;/P&gt;&lt;HR originaltext="----------------------------------------------------------------" /&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;AT SELECTION-SCREEN&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;*----&lt;/P&gt;&lt;HR originaltext="----------------------------------------------------------------" /&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;AT SELECTION-SCREEN OUTPUT.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  IF p_up = 'X' .&lt;/P&gt;&lt;P&gt;    LOOP AT SCREEN.&lt;/P&gt;&lt;P&gt;      CASE screen-group1.&lt;/P&gt;&lt;P&gt;        WHEN 'CCC'.&lt;/P&gt;&lt;P&gt;          screen-input = 1. "Enable&lt;/P&gt;&lt;P&gt;          screen-invisible = 0. "Disable&lt;/P&gt;&lt;P&gt;          MODIFY SCREEN.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;        WHEN 'DDD'.&lt;/P&gt;&lt;P&gt;          screen-input = 0.&lt;/P&gt;&lt;P&gt;          screen-invisible = 1.&lt;/P&gt;&lt;P&gt;          MODIFY SCREEN.&lt;/P&gt;&lt;P&gt;      ENDCASE.&lt;/P&gt;&lt;P&gt;    ENDLOOP.&lt;/P&gt;&lt;P&gt;    CALL FUNCTION 'F4_FILENAME'                       "allows user to select path/file&lt;/P&gt;&lt;P&gt;      EXPORTING&lt;/P&gt;&lt;P&gt;        program_name  = 'Z_TEST1'&lt;/P&gt;&lt;P&gt;        dynpro_number = syst-dynnr&lt;/P&gt;&lt;P&gt;        field_name    =  'p_pcfile'&lt;/P&gt;&lt;P&gt;      IMPORTING&lt;/P&gt;&lt;P&gt;        file_name     = p_pcfile.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  ENDIF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  IF p_list = 'X'.&lt;/P&gt;&lt;P&gt;    LOOP AT SCREEN.&lt;/P&gt;&lt;P&gt;      CASE screen-group1.&lt;/P&gt;&lt;P&gt;        WHEN 'CCC'.&lt;/P&gt;&lt;P&gt;          screen-input = 0.&lt;/P&gt;&lt;P&gt;          screen-invisible = 1.&lt;/P&gt;&lt;P&gt;          MODIFY SCREEN.&lt;/P&gt;&lt;P&gt;        WHEN 'DDD'.&lt;/P&gt;&lt;P&gt;          screen-input = 1.&lt;/P&gt;&lt;P&gt;          screen-invisible = 0.&lt;/P&gt;&lt;P&gt;          MODIFY SCREEN.&lt;/P&gt;&lt;P&gt;      ENDCASE.&lt;/P&gt;&lt;P&gt;    ENDLOOP.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Now whats going on is as soon as I run my program it asks the user to enter the location of the file, although as per the logic once user selected that the file is cioming from system using radio button then only it should ask for the file location. Moreover I will really appreciate your efforts if you can just help me out how to upload the file using ws-upload/gui-upload oncer enters the file location in detail.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;Rajeev Gupta&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Message was edited by: &lt;/P&gt;&lt;P&gt;        Rajeev Gupta&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 08 Oct 2007 15:29:43 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/selection-screen/m-p/2900972#M682179</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-10-08T15:29:43Z</dc:date>
    </item>
    <item>
      <title>Re: Selection Screen</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/selection-screen/m-p/2900973#M682180</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Put this code in a separate event -&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;At selection-screen on value-request for p_pcfile.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CALL FUNCTION 'F4_FILENAME' "allows user to select path/file&lt;/P&gt;&lt;P&gt;EXPORTING&lt;/P&gt;&lt;P&gt;program_name = 'Z_TEST1'&lt;/P&gt;&lt;P&gt;dynpro_number = syst-dynnr&lt;/P&gt;&lt;P&gt;field_name = 'p_pcfile'&lt;/P&gt;&lt;P&gt;IMPORTING&lt;/P&gt;&lt;P&gt;file_name = p_pcfile.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ashish&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 08 Oct 2007 15:33:51 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/selection-screen/m-p/2900973#M682180</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-10-08T15:33:51Z</dc:date>
    </item>
    <item>
      <title>Re: Selection Screen</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/selection-screen/m-p/2900974#M682181</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hey thanks a lot aashish, that problem is resolved now and the only problem that is left is that once user enters the file location then I need to use the gui-upload function module, so how to chieve this. I mean if user selects the file from the system then I need to use gui_upload and if user enters the file from the application server then I need to use Open data set and Read data set.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;Rajeev Gupta&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 08 Oct 2007 15:39:01 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/selection-screen/m-p/2900974#M682181</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-10-08T15:39:01Z</dc:date>
    </item>
    <item>
      <title>Re: Selection Screen</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/selection-screen/m-p/2900975#M682182</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have already given sample code in my earlier answers. Please alter the same as per your requirement. You need to pass correct internal table (as your file structure will be different).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this helps.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ashish&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 08 Oct 2007 15:41:14 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/selection-screen/m-p/2900975#M682182</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-10-08T15:41:14Z</dc:date>
    </item>
  </channel>
</rss>

