Skip to Content
avatar image
Former Member

Editable ALV : Need PERNR & ENAME on Pernr F4 help

Dear Friends,

I have created a GRID ALV for my customized HR module. In this ALV, there is a field PERNR and alongwith that there is another field ENAME.

PERNR field is editable & supported with F4 help. My requirement is like, when I change the PERNR, say, I clicked on F4 help (PREM - for PERNR) & select any PERNR, then automatically, the ENAME should get changed.

My requirement can also be achieved, if after getting the New PERNR, the user presses the ENTER button, then the ENAME of the PERNR should also get updated.

I tried to check the way with which SAP is going through the whole process by debugging (/H method).

But on clicking ENTER the control remains doesn't go anywhere, that means ENTER is not considered as an EVENT. Also, when I click on F4 Help button, the control remains in SAPLSLVC_FULLSCREEN program & it doesn't come in my Z report.

My problem can be solved in one of the following ways :

1). Can someone please tell me the way to get customized F4 help in GRID ALV & also how can I

populate ENAME alongwith PERNR in one go.

2). Any example code of OOPS ALV with this scenario. (I know, this can be done with OOPS

methods, but I'm novice in OOPS).

OR any other possible way, that you think can solve my problem.

Waiting for your replies Gurus ...

--

Thanks & Regards,

Mohit Grover

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

3 Answers

  • avatar image
    Former Member
    Feb 17, 2009 at 08:32 AM

    Hi Mohit,

    Use at selection-screen on value-request for p_name to get the F4 help!

    Much Regards,

    Amuktha.

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Feb 17, 2009 at 08:52 AM

    hi,

    AT SELECTION-SCREEN ON VALUE-REQUEST FOR P_NAME.
    
    "FUNCTION MODULE
    CALL FUNCTION 'F4_FILENAME'
    * EXPORTING
    *   PROGRAM_NAME        = SYST-CPROG "PROGRAM NAME
    *   DYNPRO_NUMBER       = SYST-DYNNR
    *   FIELD_NAME          = ' '
    * IMPORTING
    *   FILE_NAME           =      " P_NAME TYPE IBIPPARMS-PATH
    
    "OBJECTS
    CALL METHOD cl_gui_frontend_services=>file_open_dialog
    *  EXPORTING
    *    window_title            =
    *    default_extension       =
    *    default_filename        =
    *    file_filter             =
    *    with_encoding           =
    *    initial_directory       =
    *    multiselection          =
      CHANGING
        file_table              =
        rc                      =
    *    user_action             =
    *    file_encoding           =
    *  EXCEPTIONS
    *    file_open_dialog_failed = 1
    *    cntl_error              = 2
    *    error_no_gui            = 3
    *    not_supported_by_gui    = 4
    *    others                  = 5
            .
    IF sy-subrc <> 0.
    * MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    *            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.

    HAVE A GOOD DAY

    REGARDS

    SARVES

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member Former Member

      Can someone throw some light on this topic ?

      I've checked standard BCALV reports. Those are a bit typical because those reports includes so many functionalities. If anyone had encountered this problem in the past & had came up with any solution, then provide your valuable help.

      Thank You ...

  • avatar image
    Former Member
    Mar 25, 2009 at 09:30 AM

    Hi,

    Is this thread placed in the correct forum?

    Gr., Frank

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member

      Mistakenly, this thread is not in the correct forum.

      But still, any help here is welcome. I'll post this thread in another forum also.