Como agregar Botón "Refrescar" (F8) en un Reporte ALV Grid .. ?

Colapsar
X
 
  • Tiempo
  • Mostrar
Limpiar Todo
nuevos mensajes
  • gnes6
    Junior Member
    • dic
    • 12

    #1

    Como agregar Botón "Refrescar" (F8) en un Reporte ALV Grid .. ?

    Saludos a todos,

    Favor me ayudan con esto

    Cómo puedo agregar el Botón "Refrescar" (F8) a un Reporte ALV generado con la función 'REUSE_ALV_GRID_DISPLAY´...........?
    gne6
  • Mauricio Hidalgo
    Senior Member
    • may
    • 481

    #2
    1. usar los parámetro de exporting siguientes.
    i_callback_user_command = 'USER_COMMAND'
    i_callback_pf_status_set = 'SET_PF_STATUS'
    2. crear los siguientes forms

    form user_command using ucomm like sy-ucomm selfield type slis_selfield.
    data: valor_x(20) type c.
    selfield-refresh = 'X'.
    case ucomm.
    when 'REFRESCAR'.
    perform data_retrieval.
    when 'BACK'.
    leave to screen 0.
    endcase.
    endform. "USER_COMMAND

    form set_pf_status using rt_extab type slis_t_extab.
    data w_fcode type slis_extab.
    w_fcode-fcode = '&REFRESH'.
    append w_fcode to rt_extab.
    set pf-status 'STANDARD_FULLSCREEN' excluding rt_extab.
    endform.

    aquí estoy eliminando el refresh del la toolbar que trae el status que a continuación menciono.

    3. Copiar desde el mismo grupo de funciones de la REUSE_ALV_GRID_DISPLAY
    el status STANDARD_FULLSCREEN a tu programa.
    4. Agregar a este estatus tu propia función yo en el paso 2 la llame REFRESCAR (que original jajaj).


    Con eso debería ser capaz de tener tu propio refresh.


    Saludos

    Comentario

    • gnes6
      Junior Member
      • dic
      • 12

      #3
      Originalmente publicado por Mauricio Hidalgo
      1. usar los parámetro de exporting siguientes.
      i_callback_user_command = 'USER_COMMAND'
      i_callback_pf_status_set = 'SET_PF_STATUS'
      2. crear los siguientes forms

      form user_command using ucomm like sy-ucomm selfield type slis_selfield.
      data: valor_x(20) type c.
      selfield-refresh = 'X'.
      case ucomm.
      when 'REFRESCAR'.
      perform data_retrieval.
      when 'BACK'.
      leave to screen 0.
      endcase.
      endform. "USER_COMMAND

      form set_pf_status using rt_extab type slis_t_extab.
      data w_fcode type slis_extab.
      w_fcode-fcode = '&REFRESH'.
      append w_fcode to rt_extab.
      set pf-status 'STANDARD_FULLSCREEN' excluding rt_extab.
      endform.

      aquí estoy eliminando el refresh del la toolbar que trae el status que a continuación menciono.

      3. Copiar desde el mismo grupo de funciones de la REUSE_ALV_GRID_DISPLAY
      el status STANDARD_FULLSCREEN a tu programa.
      4. Agregar a este estatus tu propia función yo en el paso 2 la llame REFRESCAR (que original jajaj).


      Con eso debería ser capaz de tener tu propio refresh.


      Saludos

      MUCHAS GRACIAS MAURICIO POR TU RESPUESTA..! 10+
      gne6

      Comentario

      Trabajando...