How to set alignment of ALV heading.

Hi Experts,
In a ALV report I have created a Heading I want this heading to be displayed in the centre How to do this.
  DATA: t_header TYPE slis_t_listheader,
        wa_header TYPE slis_listheader.
/// I want this heading to be in centered/////
Heading 'Relicance Energy Limited
  wa_header-typ   = 'H'.
  wa_header-info  = text-001.
  APPEND wa_header TO t_header.
  CLEAR wa_header.
IF p_bp_ty =  1.
Premium value customer
  wa_header-typ = 'S'.
  wa_header-info = text-002.
  APPEND wa_header TO t_header.
  CLEAR wa_header.
ENDIF.
IF p_bp_ty = 2.
High value customer
wa_header-typ = 'S'.
wa_header-info = text-003.
APPEND wa_header TO t_header.
CLEAR wa_header.
ENDIF.
CALL FUNCTION 'REUSE_ALV_COMMENTARY_WRITE'
    EXPORTING
           it_list_commentary = t_header
     i_logo = 'RELMR'.
Fast response will be highly rewarded
Regards
Bikas

Check this Blog,
This is using the LVC Function module.
/people/community.user/blog/2007/01/10/displaychange-mode-of-editable-fields-in-alv-using-function-modules-but-not-custom-containers

Similar Messages

  • How to display total in ALV Header

    How to display total in ALV Header?

    Hi Venkey,
    As far as your issue is concerned I would like to quote my perception.
    Create a header internal table with title and number of records.
    At the later part of your program you should have found the total number of records ,now assign it to the header internal table and print it.
    For further clarification you can go check this link:
    http://wiki.sdn.sap.com/wiki/display/ABAP/AddHeadertoALVreport
    Thanks
    P.Srikanth

  • How to set height of JTable Header ?

    How to set height of JTable Header and set the text to another size ?

    You can set the font of the header as you can for any component. The font will dictate the preferred height of the header. If you don't like the preferred height, you can set that as well.
    // add table to a scroll pane or the header will not appear
    JTable table = new JTable(...);
    container.add(new JScrollPane(table));
    // get a reference to the header, set the font
    JTableHeader header = table.getTableHeader();
    header.setFont(new Font(...));
    // set the preferred height of the header to 50 pixels.
    // the width is ignored by the scroll pane.
    header.setPreferredSize(new Dimension(1, 50));Mitch Goldstein
    Author, Hardcore JFC (Cambridge Univ Press)
    [email protected]

  • How to set alignment in a TextField?

    I need to set allignment of the text in a TextField to right. There is no such under TextField.
    Anybody knows how to set alignment in a textfield in javaFX 2.0 ?
    Thanks

    It may be worth filing a feature request jira to get platform native support for this.
    You might think that textField.setStyle("-fx-text-alignment: right;") would work, but it does not.
    I guess that the -fx-text-alignment css property only right aligns multi-line text, not text within a text field.
    The following code uses binding to keep Text in a TextField right aligned.
    The translations place the text visually right and keyboard editing is OK.
    Mouse transparency is enabled because mouse based selections still act as though the text is left aligned.
    So it's not a complete solution.
    public void start(final Stage stage) throws Exception {
      // create a text field.
      final TextField textField = new TextField("This is right aligned text");
      textField.setStyle("-fx-text-alignment: right;");
      textField.setMinWidth(400);
      textField.setMouseTransparent(true);
      // layout the scene.
      final VBox layout = new VBox();
      layout.setStyle("-fx-background-color: cornsilk; -fx-padding: 10; -fx-alignment: center;");
      layout.getChildren().addAll(textField);
      Scene scene = new Scene(layout);
      stage.setScene(scene);
      stage.show();
      // keep the text in the textbox right aligned.
      final Text text = (Text) textField.lookup("Text");
      rightAlign(text, textField);
      textField.textProperty().addListener(new InvalidationListener() {
        @Override public void invalidated(Observable observable) {
          rightAlign(text, textField);
    private void rightAlign(Text text, TextField textField) {
      text.getParent().translateXProperty().bind(textField.widthProperty().subtract(text.xProperty().multiply(2)).subtract(text.getLayoutBounds().getWidth()));
    }

  • How to Display Logo in ALV Header?

    Hi
    I want to display/ print my company logo image in ALV Header. Please help me how can I do this?
    Thanks
    Iftikhar Ali
    Islamabad.

    Hi,
    If you are already   having a logo say ZLOGO .
    You can use it this way .
    Give TOP-OF-PAGE
    call function 'REUSE_ALV_GRID_DISPLAY'
           exporting
                i_callback_program      = gd_repid
                i_callback_top_of_page   = 'TOP-OF-PAGE'  "see FORM
                is_layout               = gd_layout
                it_fieldcat             = fieldcatalog[]
                i_save                  = 'X'
           tables
                t_outtab                = it_ekko
           exceptions
                program_error           = 1
                others                  = 2.
    And in top of page do this .
    FORM top-of-page.
    CALL FUNCTION 'REUSE_ALV_COMMENTARY_WRIT
      EXPORTING
       IT_LIST_COMMENTARY       = IT_LISTHE
       i_logo                   = 'ZLOGO'
      I_END_OF_LIST_GRID       =
    endform.
    Hope this will work .
    Reward if found useful.
    Regards
    SureshP.

  • How to set and pass a Header Varible in Jsp

    Hi ,
    I am using Headervariable login module(which takes user id form http header variable) for single sign on.
    I configured the login module stack. But to test i need a jsp from which i can pass the user id in http header.
    to test if i am able to set the user id in http header , i  have written 2 jsps
    1. Header.jsp
    In this , i am setting the user id
    response.addHeader("UserId" ,"user1");
    and i am posting it to HeaderResult.jsp
    2.HeaderResult.jsp
    In this, i am tryng to rretrieve it By using
    request.getHeader("UserId");
    But i am not geeting any value.
    Can i set user defined header variables?if not, can i set the standard http header variabes,
    Please help me with the code.
    Thanks,
    Lakshmi

    Hi Deltev,
    Yes it will be lost, should i use request.servervariable(Http_userid)?
    The Headeresult.jsp is only to test if i am able to set the header .
    Actaully ,from Header.jsp i am calling the portal(Login module stack configured to HeaderVaribleLogin).
    the poratl expects the userid  from Http Header from jsp i need to send this in header.
    How do i do this. I am missing something while passing the userid in header.
    Please lete me know.
    Thanks,
    Lakshmi

  • Hi, how to set printer to alv grid, please check my code

    Hi,
    Iam giving my code, please observe...
    DEFAULT PRINTER NAME "A909".
    NOW IAM SETTING OT "LP01".
    GS_PRINT-PRINT = 'X'.
    P_PRINTR = 'LP01'.
    CALL FUNCTION 'UPDATE_DEFAULT_PRINTPARAMS'
    EXPORTING
    USER = SY-UNAME
    DESTINATION = P_PRINTR
    IMMEDIATELY = ' '
    RELEASE = 'X'
    NEW_LIST_ID = 'X'.
    SY-BATCH = 'X'
    CALL METHOD GO_GRID->SET_TABLE_FOR_FIRST_DISPLAY
    EXPORTING
    I_BUFFER_ACTIVE =
    I_BYPASSING_BUFFER =
    I_CONSISTENCY_CHECK = G_CONSISTENCY_CHECK
    I_STRUCTURE_NAME = 'KNA1'
    IS_VARIANT = GS_VARIANT
    I_SAVE = 'A'
    I_DEFAULT = 'X'
    IS_LAYOUT = GS_LAYOUT
    IS_PRINT = GS_PRINT
    IT_SPECIAL_GROUPS =
    IT_TOOLBAR_EXCLUDING = GT_EXCLUDE
    IT_HYPERLINK =
    IT_ALV_GRAPHICS =
    IT_EXCEPT_QINFO =
    IR_SALV_ADAPTER =
    CHANGING
    IT_OUTTAB = ITAB2[]
    IT_FIELDCATALOG = GT_FIELDCAT
    IT_SORT =
    IT_FILTER =
    EXCEPTIONS
    INVALID_PARAMETER_COMBINATION = 1
    PROGRAM_ERROR = 2
    TOO_MANY_LINES = 3
    others = 4
    After running this program iam getting the default printer spool request number 'A909', Iam not getting printing form 'LP01'.
    Need is to send the print to given printer (LP01), here printer may varry accoring to the selection. So nee is to set the printer that which has choosen.
    Please give me the valuble solution as early as possible.
    Please solve this as early as possible.

    Hi Ravi,
    You can choose for the print version to be created as a PostScript file instead of a PDF document. The PostScript file is then sent directly to a printer of your choice
    If you do not specify an output device here, a PDF file is generated and displayed on the screen.
    You use the methods of the interface class IF_SALV_WD_PDF_SETTINGS for this (implementing class CL_SALV_WD_CONFIG_TABLE).
    <b>Function</b>                      <b>Method</b>
    Set ALV output to be printed immediately -->  SET_PRINT_IMMEDIATE
    Check whether the ALV output is to be printed immediately --> GET_PRINT_IMMEDIATE
    Set printer -->  SET_PRINTER
    Get printer --> GET_PRINTER
    See the below for SAP link
    http://help.sap.com/saphelp_nw04s/helpdata/en/43/27472def40601ee10000000a422035/content.htm
    see the thread also
    Re: How to set the printer in set_table_for_first_display
    mark all the helpful answers
    Regards
    Sudheer

  • How to set the default screen header structure of PA30?

    Hi,
    I am not talking about the screen header of a particular infotype, e.g. IT0002. I have managed to change the header for any infotype by changing  the structure of relevant screen header modifier.
    The question is, how to change the screen header at the initial screen of PA30?
    Because all settings in table V_582A_B are with an infotype number. No idea about how to change the default sreen header.
    thanks in advance.

    PA20 / PA30 Initial screen always maps to screen header '00' even if it's not in V_582A_B. Therefore, if you have an infotype currently maps to screen header '00' and plan to have initial screen header to be different than the header of this infotype, you'll need to re-configure this infotype to map to a different screen header.
    Rgds.

  • How to Set UserId in Http Header for SSO?

    Hello All,
    I have a requirement to set the userid into the HTTP Header so that i can use the "Header Variables for User Authentication" module provided by SAP to achieve the SSO .
    Could some 1 let me know how can I achieve this? I know abt the HTTPServlet.setheader() method, But i need to set it using my JAVA application. Is there any way to set the HTTP Header using Java. I have already done a lot of googling, but havent got any results.
    I am sure that, there must definitely be a way in which we can add the user id into the HTTP header, in all the results, they tell abt adding it using the HTTP Servlet or PHP and so on, but i need to add it from JAVA.(setting REMOTE_USER as "mysapuserid")
    I have already added the "HeaderVariableLoginModule" in my login stack in the 2nd position, as per
    http://help.sap.com/saphelp_nw04/helpdata/en/8f/ae29411ab3db2be10000000a1550b0/frameset.htm
    Any pointers will be helpful,
    Meghana
    Edited by: Meghana Phadke on Apr 14, 2008 2:49 PM

    Hi
    As I understand, your java application is an EP client, check framework HttpClient :
    http://hc.apache.org/httpclient-3.x/
    http://hc.apache.org/httpclient-3.x/tutorial.html
    Hope this help
    Jakub Krecicki

  • How to set wsse:security SOAP header in soa 11g?

    Hi,
    we are facing an issue with invoking a secured webservice.
    we tried 3 things
    1.) set the username/password in em under reference properties
    2.) Created a schema, set the username/password and included it in partner link header tab.
    3.) added a client token policy in em and then set http authentication field.
    all these not working.
    the error we are facing is :
    Non Recoverable System Fault :
    javax.xml.ws.soap.SOAPFaultException: Missing <wsse:Security> in SOAP Header
    complete payload is below:
    <bpelFault>
    <faultType>0</faultType>
    <remoteFault>
    <part name="summary">
    <summary>Missing <wsse:Security> in SOAP Header</summary>
    </part>
    <part name="detail">
    <detail>javax.xml.ws.soap.SOAPFaultException: Missing <wsse:Security> in SOAP Header</detail>
    </part>
    <part name="code">
    <code>wsse:InvalidSecurity</code>
    </part>
    </remoteFault>
    </bpelFault>
    Please let us know how to proceed with this?
    Thanks in advance
    Regards

    You need to attach the below policy in security section (Select your partnerlink in the references section of composite.xml and the click on "Configure WS policies")
    oracle/wss_username_token_client_policy
    if it is Secured Webservice, then attach this policy
    oracle/wss_username_token_over_ssl_client_policy
    After attaching policy, click edit and configure the key(out of box, u see one key csf-key) . This key should be setup with the required username and password that matches with the Webservice expected username and pwd.
    Thanks,
    Satish
    http://soadiscovery.blogspot.com

  • How to set alignment of the TextField

    What method I shall use to set is the alignment of the TextField to have is Right Aligned?
    Regds
    Jay

    I've found:
    public void setComponentOrientation(ComponentOrientation o)Sets the language-sensitive orientation that is to be used to order the elements or text within this component. Language-sensitive LayoutManager and Component subclasses will use this property to determine how to lay out and draw components.
    At construction time, a component's orientation is set to ComponentOrientation.UNKNOWN, indicating that it has not been specified explicitly. The UNKNOWN orientation behaves the same as ComponentOrientation.LEFT_TO_RIGHT.

  • How to set query title or heading

    Hi,
    How  can I set the query title or query heading. And also how can I creat text variable for query description.
    Thank you
    Joe

    Hi Joe,
    First, you can define query description when you first time save it. Then you can change it in query properties. But in the latter case the query description will be changed during the run time. When you select the query when you open it, the description will be original.
    Best regards,
    Eugene

  • How to set variant for ALV grid from ABAP

    Hello,
    I have a program which displays some data with ALV grid. Then after some operation I would like to set different layout for the grid, but not by choosing it manually but by the program. I thought that it would be enough to use the method SET_VARIANT, so I'm setting DISVARIANT structure properly, using SET_VARIANT method and after that I'm calling REFRESH_TABLE_DISPLAY but layout is not changed. What else should I do? Is that possible?
    Best regards,
    Marcin

    Hi,
    Check this
    * While declaring select-options
    parameters: p_vari        like ltdx-variant.  " Layout
    * then add the following code in
    at selection-screen on value-request for p_vari.
      perform f_variant_f4 using p_vari.
    * Code for f_variant_f4
    form f_variant_f4 using  p_vari.
    * private variables
      data : v_exit    type c.
      clear gs_variantt.
      v_variant_save = 'U'.
      call function 'LVC_VARIANT_F4'
        exporting
          is_variant    = gs_variant
          i_save        = v_variant_save
        importing
          e_exit        = v_exit
          es_variant    = gs_variantt
        exceptions
          not_found     = 1
          program_error = 2
          others        = 3.
      if sy-subrc ne c_0.
        message i999(yscc) with text-064.    " No Layout Available for F4
      endif.
      if v_exit is initial.
        gs_variant-variant = gs_variantt-variant.
        p_vari             = gs_variantt-variant.
      endif.
    endform.                                 " F_variant_f4
    * In PBO
        call method grid1->set_table_for_first_display
          exporting
            is_layout                     = gs_layout
            is_variant                    = gs_variant
            i_save                        = 'A'
            it_toolbar_excluding          = i_exclude[]
          changing
            it_outtab                     = i_output[]
            it_fieldcatalog               = i_fieldcat[]
          exceptions
            invalid_parameter_combination = 1
            program_error                 = 2
            too_many_lines                = 3
            others                        = 4.

  • How to set the border of header of JTable

    I am using the following code to set the border of my JTable headers but it doesn't seem to work!! The headers do get CENTER aligned but somehow they do not show the right border. Please Help.
    class cellAlignRenderer extends DefaultTableCellRenderer
    cellAlignRenderer()
    setHorizontalAlignment(JLabel.CENTER);
    Border b = BorderFactory.createEtchedBorder() ;
    setBorder(b);
    jTable.getColumn(0).setHeaderRenderer( new cellAlignRenderer());

    try this
    public class YourTableHeaderRenderer extends DefaultTableCellRenderer
    public YourTableHeaderRenderer()
    public Component getTableCellRendererComponent(JTable table, Object value,
    boolean isSelected, boolean hasFocus, int row, int column)
    JLabel comp = (JLabel) super.getTableCellRendererComponent(table,value,
    isSelected,hasFocus,row,column);
    try
    comp.setBorder(BorderFactory.createBevelBorder(0,Color.lightGray,Color.darkGray));
    setFont(new java.awt.Font("Dialog", 0, 15));
    setHorizontalAlignment(SwingConstants.CENTER);
    catch(Exception err)
    err.printStackTrace();
    return this;

  • How to Set Checkbox of ALV Grid Dark on Display Mode

        ABAP experts, I want to switch between display mode and edit mode for some columns of ALV Grid. So I set "LVC_S_FCAT-EDIT" "X" for the columns which need to switch mode, and use method "SET_READY_FOR_INPUT" to switch.
        Currently, the function of switch mode has been achieved. But icons of checkbox columns are light but not dark when display mode, although the columns can't be edited. (Please refer to the image below.) I want to make checkbox columns dark as other columns on display mode.
        I tried to use "CL_GUI_ALV_GRID=>MC_STYLE_ENABLED" and "CL_GUI_ALV_GRID=>MC_STYLE_DISABLED", but failed. I also studied sample program "BCALV_EDIT_05" which is related to checkbox in ALV Grid, and compared my program with this program. But I still have not found problems.
        Help me solve this problem, please.
        Part of my codes are as follows.
        Part 1:
    IF iv_is_create_group = abap_true OR iv_is_edit_group = abap_true.
           set_enable( iv_flag = 1 ).
           LOOP AT gt_acct_group_item ASSIGNING <lfs_acct_group_item>.
             CLEAR ls_celltab.
             IF <lfs_acct_group_item>-celltab IS INITIAL.
               CLEAR ls_celltab.
               ls_celltab-fieldname = 'CHECK_BOX'.
               ls_celltab-style = cl_gui_alv_grid=>mc_style_enabled.
               APPEND ls_celltab TO <lfs_acct_group_item>-celltab.
               CLEAR ls_celltab.
               ls_celltab-fieldname = 'XPORE'.
               ls_celltab-style = cl_gui_alv_grid=>mc_style_enabled.
               APPEND ls_celltab TO <lfs_acct_group_item>-celltab.
             ELSE.
               LOOP AT <lfs_acct_group_item>-celltab ASSIGNING <lfs_celltab>.
                 <lfs_celltab>-style = cl_gui_alv_grid=>mc_style_enabled.
               ENDLOOP.
             ENDIF.
           ENDLOOP.
         ELSE.
           set_enable( iv_flag = 0 ).
           LOOP AT gt_acct_group_item ASSIGNING <lfs_acct_group_item>.
             IF <lfs_acct_group_item>-celltab IS INITIAL.
               CLEAR ls_celltab.
               ls_celltab-fieldname = 'CHECK_BOX'.
               ls_celltab-style = cl_gui_alv_grid=>mc_style_disabled.
               APPEND ls_celltab TO <lfs_acct_group_item>-celltab.
               CLEAR ls_celltab.
               ls_celltab-fieldname = 'XPORE'.
               ls_celltab-style = cl_gui_alv_grid=>mc_style_disabled.
               APPEND ls_celltab TO <lfs_acct_group_item>-celltab.
             ELSE.
               LOOP AT <lfs_acct_group_item>-celltab ASSIGNING <lfs_celltab>.
                 <lfs_celltab>-style = cl_gui_alv_grid=>mc_style_disabled.
               ENDLOOP.
             ENDIF.
           ENDLOOP.
         ENDIF.
         CALL METHOD gr_grid->refresh_table_display
    *      EXPORTING
    *        is_stable      =
    *        i_soft_refresh =
           EXCEPTIONS
             finished       = 1
             OTHERS         = 2
         IF sy-subrc <> 0.
    *     Implement suitable error handling here
         ENDIF.
        Part 2:
    METHOD set_enable.
         gr_grid->set_ready_for_input(
             i_ready_for_input = iv_flag
    ENDMETHOD.

    Hi Liu,
        Please go through the below code.
    *& Report  YEDIT_DISPLAY
    REPORT  YEDIT_DISPLAY.
    TABLES : VBAK.
    TYPE-POOLS SLIS.
    TYPES : BEGIN OF TY_VBAK,
              VBELN TYPE VBAK-VBELN,
             END OF TY_VBAK,
             BEGIN OF TY_FINAL,
               BOX TYPE C,
               VBELN TYPE VBAK-VBELN,
             END OF TY_FINAL.
    DATA : IT_VBAK TYPE TABLE OF TY_VBAK,
            WA_VBAK TYPE TY_VBAK,
            IT_FINAL TYPE TABLE OF TY_FINAL,
            WA_FINAL TYPE TY_FINAL,
            IT_FCAT TYPE TABLE OF SLIS_FIELDCAT_ALV,
            WA_FCAT TYPE SLIS_FIELDCAT_ALV.
    START-OF-SELECTION.
       PERFORM FETCH_DATA.
       PERFORM FCAT_DATA.
       PERFORM DISPLAY.
    *&      Form  FETCH_DATA
    *       text
    *  -->  p1        text
    *  <--  p2        text
    FORM FETCH_DATA .
       SELECT VBELN INTO TABLE IT_VBAK FROM VBAK UP TO 10 ROWS.
       LOOP AT IT_VBAK INTO WA_VBAK.
         WA_FINAL-VBELN = WA_VBAK-VBELN.
         APPEND WA_FINAL TO IT_FINAL.
         CLEAR : WA_FINAL , WA_VBAK.
       ENDLOOP.
    ENDFORM.                    " FETCH_DATA
    *&      Form  FCAT_DATA
    *       text
    *  -->  p1        text
    *  <--  p2        text
    FORM FCAT_DATA .
       WA_FCAT-COL_POS = 1.
       WA_FCAT-FIELDNAME = 'BOX'.
       WA_FCAT-TABNAME = 'IT_FINAL'.
       WA_FCAT-OUTPUTLEN = '3'.
       WA_FCAT-SELTEXT_M = 'BOX'.
       wa_fcat-checkbox = 'X'.
       WA_FCAT-EDIT = 'X'.
       APPEND WA_FCAT TO IT_FCAT.
       CLEAR WA_FCAT.
       WA_FCAT-COL_POS = 2.
       WA_FCAT-FIELDNAME = 'VBELN'.
       WA_FCAT-TABNAME = 'IT_FINAL'.
       WA_FCAT-OUTPUTLEN = '3'.
       WA_FCAT-SELTEXT_M = 'Sales Document'.
       APPEND WA_FCAT TO IT_FCAT.
       CLEAR WA_FCAT.
    ENDFORM.                    " FCAT_DATA
    *&      Form  DISPLAY
    *       text
    *  -->  p1        text
    *  <--  p2        text
    FORM DISPLAY .
       CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
        EXPORTING
    *   I_INTERFACE_CHECK                 = ' '
    *   I_BYPASSING_BUFFER                = ' '
    *   I_BUFFER_ACTIVE                   = ' '
          I_CALLBACK_PROGRAM                = SY-REPID
    *   I_CALLBACK_PF_STATUS_SET          = ' '
        I_CALLBACK_USER_COMMAND           = 'USER_COMMAND'
    *   I_CALLBACK_TOP_OF_PAGE            = ' '
          IT_FIELDCAT                       = IT_FCAT
    *   I_DEFAULT                         = 'X'
    *   I_SAVE                            = ' '
         TABLES
           T_OUTTAB                          = IT_FINAL
    * EXCEPTIONS
    *   PROGRAM_ERROR                     = 1
    *   OTHERS                            = 2
       IF SY-SUBRC <> 0.
    * Implement suitable error handling here
       ENDIF.
    ENDFORM.                    " DISPLAY
    FORM USER_COMMAND USING UCOMM TYPE SY-UCOMM
                             RTAB TYPE slis_selfield.
       CASE UCOMM.
         WHEN '&IC1'.
           MESSAGE 'SUCESSFUL' TYPE 'S'.
         WHEN '&DATA_SAVE'.
           PERFORM FIL_FCAT.
           PERFORM DISPLAY1.
         WHEN 'BACK'.
           LEAVE TO SCREEN 0.
         WHEN OTHERS.
           LEAVE TO SCREEN 0.
       ENDCASE.
    ENDFORM.
    *&      Form  FIL_FCAT
    *       text
    *  -->  p1        text
    *  <--  p2        text
    FORM FIL_FCAT .
    CLEAR IT_FCAT.
       WA_FCAT-COL_POS = 1.
       WA_FCAT-FIELDNAME = 'BOX'.
       WA_FCAT-TABNAME = 'IT_FINAL'.
       WA_FCAT-OUTPUTLEN = '3'.
       WA_FCAT-SELTEXT_M = 'BOX'.
       wa_fcat-checkbox = 'X'.
    **  WA_FCAT-EDIT = 'X'.
       APPEND WA_FCAT TO IT_FCAT.
       CLEAR WA_FCAT.
       WA_FCAT-COL_POS = 2.
       WA_FCAT-FIELDNAME = 'VBELN'.
       WA_FCAT-TABNAME = 'IT_FINAL'.
       WA_FCAT-OUTPUTLEN = '3'.
       WA_FCAT-SELTEXT_M = 'Sales Document'.
       APPEND WA_FCAT TO IT_FCAT.
       CLEAR WA_FCAT.
    ENDFORM.                    " FIL_FCAT
    *&      Form  DISPLAY1
    *       text
    *  -->  p1        text
    *  <--  p2        text
    FORM DISPLAY1 .
    CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
        EXPORTING
    *   I_INTERFACE_CHECK                 = ' '
    *   I_BYPASSING_BUFFER                = ' '
    *   I_BUFFER_ACTIVE                   = ' '
          I_CALLBACK_PROGRAM                = SY-REPID
    *   I_CALLBACK_TOP_OF_PAGE            = ' '
          IT_FIELDCAT                       = IT_FCAT
    *   I_DEFAULT                         = 'X'
    *   I_SAVE                            = ' '
         TABLES
           T_OUTTAB                          = IT_FINAL
    * EXCEPTIONS
    *   PROGRAM_ERROR                     = 1
    *   OTHERS                            = 2
       IF SY-SUBRC <> 0.
    * Implement suitable error handling here
       ENDIF.
    ENDFORM.                    " DISPLAY1
    Here i written code under the SAVE button , if requires you create your own status and apply.
    Regards,
    Krishna

Maybe you are looking for