Selection screen help

In report program, how can i get the default screen values as current month's low and high values as sy-datum will only give current date. i. e. suppose today it is dec 30 then, default low value should show dec 01 and high should show dec 31. please help.

Here it goes...
DATA: lv_begda TYPE sy-datum,
      lv_endda TYPE sy-datum.
INITIALIZATION.
  CALL FUNCTION 'HRWPC_BL_DATES_MONTH_INTERVAL'
    EXPORTING
      datum          = sy-datum
      month_pst      = 0
      month_ftr      = 0
    IMPORTING
      begda          = lv_begda
      endda          = lv_endda
    EXCEPTIONS
      invalid_values = 1
      OTHERS         = 2.
  IF sy-subrc = 0.
    WRITE: lv_begda,
          / lv_endda.
  ENDIF.
START-OF-SELECTION.
Regards,
Shailaja

Similar Messages

  • Selection Screen - Help required

    Hi ,
    I am developing a SD report in which he selection screen is executed without any inputs it shows me the customers which are maintained against my ID in a Ztable.
    However customer needs for internal users he should be able to view all without any inputs.
    can anyone help me..?
    Varun

    hi Varun,
    do not include the user id on the where condition on your select statement.
    regards,
    Peter

  • LDB  SELECTION SCREEN HELP

    Hi,
    In ldb when when we go for selection system suggests
    1.nodes for which free selections are generated.
    2.nodes for which fields selections are to be generated
    please explain what does both option means.
    thanks in advance.

    Hi Manish
    Dynamic Selections
          The tables defined in the structure can have dynamic selections using the following
            code  in the Selections Include program
    SELECTION-SCREEN DYNAMIC  SELECTION FOR TABLE <tbnam>
      Field Selections
          The tables for which field selection is defined can be called from the ABAP/4 program
            using GET <tbnam> Fields <f1> ….<fn> addition . The code for field selection in the
    SELECTION-SCREEN FIELD SELECTION FOR TABLE <tbnam>
    regards
    kishore

  • Dynamic Selection Screen Help

    Hi,
    I am trying to create a report screen with dynamics call....
    I have a Sales Order select-option no interval and no extension
    then i have few Parameters below such as
    Customer Name, Part No, Material...
    Whenever i select a SO, the screen will refresh and the value Customer Name, Part No and Material will reflects based on my selected SO.
    Any experts can tell me, how can i do this..can it be done in normal report screen or needed dialog programming.............
    urgently needed
    Thanks

    Maybe below is what you are looking for, though the requirement doesnt really make any sense to me.
    tables: vbak, vbap.
    select-options: s_vbeln for vbak-vbeln no intervals no-extension modif
    id ABC.
    parameters: p_kunnr like vbak-kunnr,
                p_matnr like vbap-matnr.
    at selection-screen output.
      if not s_vbeln[] is initial.
         select a~kunnr b~matnr into (p_kunnr, p_matnr)
                from vbak as a
                inner join vbap as b
                on a~vbeln = b~vbeln
                where a~vbeln in s_vbeln.
         endselect.
      endif.
    Kind Regards
    Eswar

  • Selection screen Help required urgently?

    Hi experts,
    I need to gve a popup on slection. This popup will contain table with col1 and col2.
    The user needs to enter data in this..
    I tried using table control, but I am not able to handle it properly..
    Can you please help me with a sample code of report similiar to above..
    Its urgent

    data : itabt like sval occurs 0 with header line.
    itabt-tabname = 'MARA'.
    itabt-fieldname = 'MATNR'.
    append itabt.
    itabt-tabname = 'MARD'.
    itabt-fieldname = 'LGORT'.
    append itabt.
    CALL FUNCTION 'POPUP_GET_VALUES'
      EXPORTING
      NO_VALUE_CHECK        = ' '
        POPUP_TITLE           = 'Enter value'
       START_COLUMN          = '5'
       START_ROW             = '5'
    IMPORTING
      RETURNCODE            =
      TABLES
        FIELDS                = itabt
    EXCEPTIONS
      ERROR_IN_FIELDS       = 1
      OTHERS                = 2
    IF SY-SUBRC <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    you can use return code also.
    regards
    shiba dutta

  • WBS Element  in selection screen

    hi,
    WBS Element in selection screen of the report need to be added from BSEG table of field PROJK.
    requirement is
    for eg- if you take a WBS Element suppose 11020017 and you put in BSEG table give the values as
    BUKRS= 0010
    GJAHR =2008
    PROJK =11020017 it gives a message WBS Element 11020017 does not exist.
    where as this WBS element if you insert in Function module  CONVERSION_EXIT_ABPSP_OUTPUT
    input as 11020017 , you will get output as 1000050-01.
    and again goto BSEG table and give the values as
    BUKRS= 0010
    GJAHR =2008
    PROJK =1000050-01, now u will get the value of  WBS Element as 11020017 .
    in the report the bussiness requires WBS Element in selection screen , the user gives the value of WBS Element in selection screen 11020017,it gives a message WBS Element 11020017 does not exist, the user should give this value1000050-01, but user doesnot know this value,user knows only 11020017 value.
    now if the user gives in selection screen 11020017 it should work i mean it must convert  to 1000050-01.
    how to use function module in selection screen.help with code
    thanks in advance

    Hi,
         Use in following way, declare a parameter P_PROJK as character type, if you declare it as TYPE BSEG-PROJK system will defaultly check in dadabase table.
    PARAMETERS : p_projk(10) TYPE c.
    AT SELECTION-SCREEN.
      CALL FUNCTION 'CONVERSION_EXIT_ABPSP_OUTPUT'
        EXPORTING
          input  = p_projk
        IMPORTING
          output = p_projk.
    START-OF-SELECTION.
      BREAK-POINT.
    Regards
    Bala Krishna

  • Help Needed in At selection screen output

    Hi Experts,
    I need your help in AT SELECTION SCREEN OUTPUT event. My issue is i have 4 radio button and with each radio button couple of parameters that need to be filled in selection screen of report. My requirement is that sometimes user enters details in second radio button parameters but forgot to change the radio button to second one so kindly suggest a solution so that radio button gets selected as per user input in parameter like if user clicks on certain parameter to enter value then automatically corresponding radio button gets selected.
    Thanks in advance for all your help.

    example from a checkbox in one of my progs..but you can do same approach with radio butts
    parameters p_test as checkbox default abap_on user-command test.
    at selection-screen.
        if sy-ucomm = 'TEST'.
          perform birth_mnth_chck.
        endif.

  • Help needed in selection screen - Urgent

    Hi Experts,
    I have a selection screen. I have three radi buttons in that selection screen. Based on the selection of the radio buttons I need to activate corresponding selection screen parameters.
    e.g : if radiobutton1 is selected, njo activation needed,
           if radiobutton2 is selected, activate selection screen parameter p_one,
           if radiobutton3 is selected, activate selection screen parameter p_two.
    All three radiobuttons are attached to the same radio button group.
    I have assigned the parameters p_one, p_two, p_three to MODIF ID as follows.
    p_one - NULL
    p_two - t01
    p_three - t02.
    on the selection of a radio button I want the corresponding parameter to get activated.
    please help me.
    Regards,
    Arul jothi A.

    hi
    jothi
    AT SELECTION-SCREEN OUTPUT.                                      
      CASE SY-TCODE.                                                 
        WHEN 'ZEDI6'.                                                
          LOOP AT SCREEN.                                             
            CASE SCREEN-GROUP4.                                      
              WHEN '001'.                  "Sales order select       
                SCREEN-ACTIVE = '1'.       "1=Active, 0=Don't display
                MODIFY SCREEN.                                       
              WHEN '002'.                  "Delivery select          
                SCREEN-ACTIVE = '0'.       "1=Active, 0=Don't display
                MODIFY SCREEN.                                        
              WHEN '003'.                  "Invoice select           
                SCREEN-ACTIVE = '0'.       "1=Active, 0=Don't display
                MODIFY SCREEN.                                       
              WHEN '004'.                  "PO Select                
                SCREEN-ACTIVE = '0'.       "1=Active, 0=Don't display
                MODIFY SCREEN.                                       
    regards
    praveen

  • Need help to disable input selection-screen - very urgent

    Hi SAP experts,
    I have a requirement where in I need to disable ( Grey out ) the input fileds on the selection screen .
    My problem is as I am using ABAP query I am not able to use any events ( AT SELECTION-SCREEN OUTPUT ).
    My selection screen looks like this
    MATERIAL NUMBER ( SELECT-OPTIONS)
    MATERIAL TYPE ( PARAMETERS )
    Now I want to add one more check box below the above fields on the selection-screen.When I click on the check-box,the MATERIAL NUMBER  must be greyed out and MATERIAL TYPE should remain the same.
    Please let me know the coding for the same. All answers would be rewarded.
    Thanks in Advance,
    Suresh.

    Hi,
    Check out these codes.
    1.
    TABLES : mara, makt.
    parameter: p_matnr type mara-matnr,
               p_maktx type makt-maktx.
    at selection-screen output.
    select single maktx
    from makt
    into p_maktx
    where matnr = p_matnr
    and spras = 'EN'.
    loop at screen.
      if screen-name = 'P_MAKTX'.
        screen-input = 0.
        modify screen.
      endif.
    endloop.
    2.
    TABLES : mara, makt.
    TYPES:BEGIN OF tp_maktx,
          maktx TYPE makt-maktx,
          END OF tp_maktx.
    DATA:t_maktx TYPE STANDARD TABLE OF tp_maktx,
         wa_maktx TYPE tp_maktx.
    SELECT-OPTIONS: s_matnr FOR mara-matnr.
    SELECT-OPTIONS: s_maktx FOR makt-maktx.
    INITIALIZATION.
      REFRESH s_maktx[].
    AT SELECTION-SCREEN OUTPUT.
      LOOP AT SCREEN.
        IF screen-name = 'S_MAKTX-LOW' or screen-name = 'S_MAKTX-HIGH'.
          screen-input = 0.
          MODIFY SCREEN.
        ENDIF.
      ENDLOOP.
      REFRESH s_maktx[].
      if s_matnr[] is not initial.
      SELECT maktx FROM makt
      INTO TABLE t_maktx
      WHERE matnr IN s_matnr
      AND spras = 'EN'.
      endif.
      LOOP AT t_maktx INTO wa_maktx.
        s_maktx-low = wa_maktx-maktx.
        APPEND s_maktx.
        CLEAR:wa_maktx.
      ENDLOOP.
    3.
    TABLES : mara, makt.
    parameter p_cb1 type c as checkbox.
    parameter p_cb2 type c as checkbox.
    parameter p_cb3 type c as checkbox.
    initialization.
    loop at screen.
    if screen-name = 'P_CB3'.
    screen-invisible = 1.
    modify screen.
    endif.
    endloop.
    at selection-screen output.
    *loop at screen.
    *if screen-name = 'P_CB3'.
    *screen-invisible = 1.
    *modify screen.
    *endif.
    *endloop.
    loop at screen.
    if p_cb1 = 'X'.
      if screen-name = 'P_CB2'.
      screen-invisible = 1.
      modify screen.
      endif.
      if screen-name = 'P_CB3'.
      screen-invisible = 0.
      modify screen.
      endif.
    endif.
    if p_cb2 = 'X'.
      if screen-name = 'P_CB3'.
      screen-invisible = 1.
      modify screen.
      endif.
      if screen-name = 'P_CB1'.
      screen-invisible = 0.
      modify screen.
      endif.
    endif.
    if p_cb3 = 'X'.
      if screen-name = 'P_CB1'.
      screen-invisible = 1.
      modify screen.
      endif.
      if screen-name = 'P_CB2'.
      screen-invisible = 0.
      modify screen.
      endif.
    endif.
    endloop.
    Reward if helpful..
    Regards.

  • How to create a F4 help for a report selection screen field

    hi,
    can any one guide me to create F4 help for a field in a selection screen in a report program,plz give me a sample code

    hi,
    Here are the following ways
    1.with the help of match code objects we can create the F4 Functionality for Field.
    Syntax is :
    PARAMETERS: p_org LIKE t527x-orgeh MATCHCODE OBJECT zorg.
    2. One more thing is we can do it with Search Help's also.
    3. Even we can do it HELP Views also.
    Help Views:
    You have to create a help view if a view with outer join is needed as selection method of a search help
    The selection method of a search help is either a table or a view. If you have to select data from several tables for the search help, you should generally use a database view as selection method. However, a database view always implements an inner join. If you need a view with outer join for the data selection, you have to use a help view as selection method.
    All the tables included in a help view must be linked with foreign keys. Only foreign keys that have certain attributes can be used here. The first table to be inserted in the help view is called the primary table of the help view. The tables added to this primary table with foreign keys are called secondary tables.
    The functionality of a help view has changed significantly between Release 3.0 and Release 4.0. In Release 3.0, a help view was automatically displayed for the input help (F4 help) for all the fields that were checked against the primary table of the help view. This is no longer the case in Release 4.0.
    As of Release 4.0, you must explicitly create a search help that must be linked with the fields for which it is offered (see Linking Search Helps with Screen Fields ).
    Existing help views are automatically migrated to search helps when you upgrade to a release higher than 4.0.
    A help view implements an outer join, i.e. all the contents of the primary table of the help view are always displayed. You therefore should not formulate a selection condition for fields in one of the secondary tables of the help view. If records of these secondary tables cannot be read as a result of this selection condition, the contents of the corresponding fields of the secondary table are displayed with initial value.
    <REMOVED BY MODERATOR>
    Edited by: Alvaro Tejada Galindo on Feb 15, 2008 3:15 PM

  • Regarding Search help on selection-screen field

    Hi there,
    I am working on custom tables.
    I have a requirement to maintain search pattern on a selection-screen field.
    selection-screen parameter: p_name which is company name filed from Z table.
    By giving a string like Holl* and by  pressing F4 on the field p_name it has to popup a dialogbox having list of company names starting with Holl.
    Thanks in advance.
    -Tulasi

    Hi
    Go through the link given below :
    How to create a search help for my own fields in selection screen
    F4 search help on report selection screen
    also try :
    CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
    EXPORTING
    DDIC_STRUCTURE = ' '
    RETFIELD = 'VKORG'
    PVALKEY = ' '
    DYNPPROG = SY-REPID
    DYNPNR = SY-DYNNR
    DYNPROFIELD = 'P_VKORG'
    STEPL = 0
    WINDOW_TITLE =
    VALUE = ' '
    VALUE_ORG = 'C'
    TABLES
    VALUE_TAB = T_TABLE1
    FIELD_TAB = field_tab
    RETURN_TAB = RET_TAB
    DYNPFLD_MAPPING = DYN_TAB
    EXCEPTIONS
    PARAMETER_ERROR = 1
    NO_VALUES_FOUND = 2
    OTHERS = 3
    With Regards
    Nikunj shah

  • How to get the F4 help for a field in the selection screen

    Hi all,
    I am working on a report program. In the selection screen, I have the field 'Brand Node ID'(ZNODEID). The requirement is to have the F4 help for this field. This field is available in a 'Z' table ZNODETAB. There is no Value table maintained for the corresponding data element. So, without disturbing the table data element/domain, I should get the F4 help in the selection screen of the report. In the F4 help, data should be fetched from the table ZNODETAB and the field is ZNODEID. Is there any way to do this.
    By searching the function modules, I could find that, we can use the FM F4IF_INT_TABLE_VALUE_REQUEST. But, I am not Sure. Can someone tell me the parameters to be passed to this function module to get the F4 help and the procedure to follow. S_NODEID is the select option used in the program. Please help me in this regard. Thanks in advance.
    Thanks & Regards,
    Paddu.

    look at this code and try
    select-options : S_NODEID for ZNODETAB-ZNODEID.
    at selection-screen on value-request for s_nodeid-low
    perform f4_nodeid using 'S_NODEID-LOW'.
    at selection-screen on value-request for s_nodeid-low
    perform f4_nodeid using 'S_NODEID-HIGH'.
    end-of-selection.
    FORM f4_nodeid  USING    p_field.
      declare it_node.
    select znodeid from ZNODETAB into table it_node.
      CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
        EXPORTING
          retfield        = 'ZNODEID'
          dynpprog        = sy-repid
          dynpnr          = sy-dynnr
          dynprofield     = p_field
          value           = space
          value_org       = 'S'
          display         = 'F'
        TABLES
          value_tab       = it_node
        EXCEPTIONS
          parameter_error = 1
          no_values_found = 2
          OTHERS          = 3.
    endform

  • Def a value in sear help of select screen generated by HR  report category

    Hi all,
    Ive developed a HR report in which Ive used LDB  PNP.. Now they are going to use this report for a particular company.
    so in the report selection screen when they choose f4 help of personnel area i.e. field PNPWERKS, I need to default a value X for company code input field(BUKRS). so that the user can select personnel area pertaining to this company (code - X).
    How can I achieve this? (defaulting a selection value in standard search help)
    Thanks,
    Rajan U

    Hi Rajan
    You can still do this in the initialization.
    The memory id for the company code is 'BUK' and for plant it is 'PBR'. So in the Initialization event you can do like below. Here I am defaulting both the company code and plant.
    insert personnel area code from user own data       
      GET PARAMETER ID 'PBR' FIELD werksid.                 
      IF NOT werksid IS INITIAL.                               
        pnpwerks-sign = 'I'. pnpwerks-option = 'EQ'.
        pnpwerks-low = werksid. APPEND pnpwerks
      ENDIF.                                                   
    insert company code from user own data
      GET PARAMETER ID 'BUK' FIELD bukrsid. 
      IF NOT bukrsid IS INITIAL.                          
        pnpbukrs-sign = 'I'. pnpbukrs-option = 'EQ'.
        pnpbukrs-low = bukrsid. APPEND pnpbukrs.
      ENDIF.
    Let me know if this helps.
    Regards,
    Vijay V

  • F4 Help for the selection screen field

    Hi Gurus,
    I have to display F4 help for a selection screen field. i am using following code:
        CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
             EXPORTING
                  retfield        = 'CODE'
                  dynpprog        = lw_repid
                  dynpnr          = sy-dynnr
                  VALUE_ORG       = 'S'
             TABLES
                  value_tab       = gi_text
                 field_tab       = li_fields_tab
                  return_tab      = pi_return_tab
             EXCEPTIONS
                  parameter_error = 1
                  no_values_found = 2
                  OTHERS          = 3.
    My internal table gi_emp has two fields CODE & TEXT. When i select 1 particular value, it returns the CODE value in the pi_return_tab table.
    But my requirement is i have to capture the corresponding TEXT value for the Returned CODE. Ex: following is the F4 help being displayed: -
    001    test
    001    test1
    but is i select code 001(First Value), i also need to capture it's corresponding Text value. In return table pi_return_tab i have only Code value.
    Please help me out.
    Note: Based on return code i can't search into the internal table gi_code, because as shown in the example, code has multiple text.

    Sachin,
    I think this is what you need. The following code will return the key and the text (OR any other columns), if both columns are in the selection screen the selected values (both columns) will also be passed to the corresponding parameters. If you only need the text to be in the return table and not passed to the selection screen then set the parameter for text with NO-DISPLAY option.
    REPORT zktest01 .
    DATA :
      BEGIN OF value_tab OCCURS 0,
        field  LIKE e070-trkorr,
        text   LIKE e07t-as4text,
      END OF value_tab.
    DATA: t_fldtab LIKE dfies OCCURS 0 WITH HEADER LINE,
          t_rettab LIKE ddshretval OCCURS 0 WITH HEADER LINE,
          t_dynmap LIKE dselc OCCURS 0 WITH HEADER LINE.
    PARAMETERS : p_field  LIKE value_tab-field,
                 p_text   LIKE value_tab-text. "NO-DISPLAY.
    INITIALIZATION.
      t_fldtab-tabname   = 'VALUE_TAB'.
      t_fldtab-fieldname = 'FIELD'.
      t_fldtab-langu     = 'E'.
      t_fldtab-position  = 1.
      t_fldtab-offset    = 0.
      t_fldtab-fieldtext = 'Key'.
      t_fldtab-reptext   = 'Key'.
      t_fldtab-leng      = 20.
      t_fldtab-intlen    = 20.
      t_fldtab-outputlen = 20.
      t_fldtab-datatype  = 'CHAR'.
      t_fldtab-inttype   = 'C'.
      t_fldtab-headlen   = 20.
      t_fldtab-keyflag   = 'X'.
      t_fldtab-lowercase = ' '.
      APPEND t_fldtab.
      t_fldtab-tabname   = 'VALUE_TAB'.
      t_fldtab-fieldname = 'TEXT'.
      t_fldtab-position  = 2.
      t_fldtab-offset    = 20.
      t_fldtab-fieldtext = 'Text'.
      t_fldtab-reptext   = 'Text'.
      t_fldtab-leng      = 60.
      t_fldtab-intlen    = 60.
      t_fldtab-outputlen = 60.
      t_fldtab-headlen   = 60.
      t_fldtab-keyflag   = ' '.
      t_fldtab-lowercase = ' '.
      APPEND t_fldtab.
      value_tab-field = '101'.
      value_tab-text = 'dddd'.
      APPEND value_tab.
      value_tab-field = '202'.
      value_tab-text = 'aaaa'.
      APPEND value_tab.
      t_dynmap-fldname = 'FIELD'.
      t_dynmap-dyfldname = 'P_FIELD'.
      APPEND t_dynmap.
      t_dynmap-fldname = 'TEXT'.
      t_dynmap-dyfldname = 'P_TEXT'.
      APPEND t_dynmap.
    AT SELECTION-SCREEN ON VALUE-REQUEST FOR p_field.
      CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
           EXPORTING
                retfield        = 'FIELD'
                dynpprog        = 'ZKTEST01'
                dynpnr          = '1000'
                dynprofield     = 'P_FIELD'
                value_org       = 'S'
           TABLES
                field_tab       = t_fldtab
                value_tab       = value_tab
                return_tab      = t_rettab
                dynpfld_mapping = t_dynmap
           EXCEPTIONS
                parameter_error = 1
                no_values_found = 2
                OTHERS          = 3.
      IF sy-subrc EQ 0.
      ENDIF.
    START-OF-SELECTION.
    Jeffrey Satriadi

  • Help on a selection screen

    I need some help on a selection screen.  I have the following:
    SELECTION-SCREEN: BEGIN OF BLOCK a1 WITH FRAME TITLE text-001.
    PARAMETERS:       p_bldat TYPE bkpf-bldat OBLIGATORY DEFAULT sy-datum,
                      p_budat TYPE bkpf-budat OBLIGATORY DEFAULT sy-datum,
                      p_xref1 TYPE proj-pspid OBLIGATORY,
                      p_bktxt TYPE bkpf-bktxt,
                      p_bukrs TYPE bkpf-bukrs OBLIGATORY DEFAULT '1100',
                      p_waers TYPE bkpf-waers OBLIGATORY DEFAULT 'USD'.
    SELECTION-SCREEN: END OF BLOCK a1.
    SELECTION-SCREEN: BEGIN OF BLOCK b1 WITH FRAME TITLE text-002.
    PARAMETERS:       p_lifnr TYPE ekko-lifnr OBLIGATORY,
                      p_ebeln TYPE ekko-ebeln OBLIGATORY.
    SELECTION-SCREEN: END OF BLOCK b1.
    SELECTION-SCREEN: BEGIN OF BLOCK c1 WITH FRAME TITLE text-003.
    PARAMETERS:       p_amt TYPE wrbtr,
                      p_ret  TYPE wrbtr.
    SELECTION-SCREEN: END OF BLOCK c1.
    SELECTION-SCREEN: BEGIN OF BLOCK d1 WITH FRAME TITLE text-004.
    PARAMETERS:       p_cmode  TYPE callmode DEFAULT 'N' OBLIGATORY.
    SELECTION-SCREEN: END OF BLOCK d1.
    AT SELECTION-SCREEN ON p_ebeln.
      SELECT SINGLE kwert INTO p_ret FROM zretention WHERE ebeln = p_ebeln AND ebelp = '00000' AND TYPE = 'C'.
      IF NOT sy-subrc = 0 OR p_ret IS INITIAL.
        CONCATENATE 'Purchase Order' p_ebeln 'does not have any retention available for release!' INTO d_string.
        MESSAGE d_string TYPE 'E'.
      ENDIF.
    AT SELECTION-SCREEN.
      check p_ret is not INITIAL.
      IF p_amt > p_ret.
        MESSAGE 'Amt. To Be Released is more than the remaining retention. Please check your input.' TYPE 'E'.
      ELSEIF p_amt IS INITIAL.
        MESSAGE 'Amt. To Be Released is required. Please check your input.' TYPE 'E'.
      ENDIF.
    What I want is for the parameter p_ret to be populated when the user inputs a PO (p_ebeln).  This seems to work except I want this to be brought in without running through the other checks (AT SELECTION-SCREEN).  In order to bring in p_ret I am having to hit ENTER which will trigger the event AT SELECTION-SCREEN.
    How can I bring in p_ret without triggering the event AT SELECTION-SCREEN?
    Regards,
    Davis

    In this case.
    If you don't want at selection-screen to be triggered on hitting enter, you can give an if condition in at selection-screen.
    tables : sscrfields.
    AT SELECTION-SCREEN ON p_ebeln.
      SELECT SINGLE kwert INTO p_ret FROM zretention WHERE ebeln = p_ebeln AND ebelp = '00000' AND TYPE = 'C'.
      IF NOT sy-subrc = 0 OR p_ret IS INITIAL.
        CONCATENATE 'Purchase Order' p_ebeln 'does not have any retention available for release!' INTO d_string.
       clear sscrfield-ucomm.
        MESSAGE d_string TYPE 'E'.
      ENDIF.
    AT SELECTION-SCREEN.
    if sscrfields-ucomm = 'ONLI'.
      check p_ret is not INITIAL.
      IF p_amt > p_ret.
        MESSAGE 'Amt. To Be Released is more than the remaining retention. Please check your input.' TYPE 'E'.
      ELSEIF p_amt IS INITIAL.
        MESSAGE 'Amt. To Be Released is required. Please check your input.' TYPE 'E'.
      ENDIF.
    endif.
    The code in at selection-screen is executed only when user presses F8. on pressing 'Enter' it will not be executed.
    Hope this helps you.
    Regards,
    Siddarth

Maybe you are looking for