ALV GRID - Text for Grand Total

Hi guys,
In ALV Grid, i need to display the Text 'GRAND TOTAL' at the left side of the row(Yellow line).
I have tried searching in the forum but didn't get the answer.
Please advice.
Thanks
Chintu

Hi
<br><br>
IF you copy and past this might not work but this is the sample code<br><br>
<pre>
REPORT  Y_DOWN_TIME_ENTRYSRA.
TABLES : YDOWNTIME1.
TYPE-POOLS : SLIS.
*INTERNAL TABLE DECLARTION
data : l_layout type slis_layout_alv,
       x_events type slis_alv_event,
       it_events type slis_t_event.
DATA :ITAB LIKE YDOWNTIME1 OCCURS 0 WITH HEADER LINE .
data :  GT_FIELDCAT TYPE SLIS_T_FIELDCAT_ALV,
      wa_FIELDCAT TYPE SLIS_T_FIELDCAT_ALV.
**********************SELECTION PARAMETERS ************************
PARAMETERS: CB1 RADIOBUTTON GROUP G1 ,
            CB2 RADIOBUTTON GROUP G1 ,
            cb3 RADIOBUTTON GROUP G1 ,
            CB4 RADIOBUTTON GROUP G1 ,
            CB5 RADIOBUTTON GROUP G1 ,
            CB6 RADIOBUTTON GROUP G1 ,
            CB7 RADIOBUTTON GROUP G1 ,
            CB8 RADIOBUTTON GROUP G1 ,
            CB9 RADIOBUTTON GROUP G1 .
           CB10 RADIOBUTTON GROUP G1,
           CB11 RADIOBUTTON GROUP G1.
DATA : A TYPE C.
SELECTION-SCREEN BEGIN OF BLOCK BK1 WITH FRAME TITLE TEXT-001.
  SELECT-OPTIONS :S_EQUNR         FOR  YDOWNTIME1-EQUNR ,
                  S_ERDop        FOR  YDOWNTIME1-ERDAT,
                  S_MFSTT         FOR  YDOWNTIME1-MFSTART.
  PARAMETERS :    P_SHIFT         TYPE YDOWNTIME1-SHIFT,
                  P_CHARG         TYPE YDOWNTIME1-CHARG,
                  p_COGRU         TYPE YDOWNTIME1-QMGRP,
                  P_CODE          TYPE YDOWNTIME1-COde,
                 p_name          type ydowntime1-OPNAME,
                  p_sup           TYPE YDOWNTIME1-SUPERVISOR,
                  P_MANG           TYPE YDOWNTIME1-MANG.
SELECTION-SCREEN END OF BLOCK BK1 .
AT SELECTION-SCREEN.
  IF CB1 EQ 'X'.
    select  * from YDOWNTIME1
         INTO  CORRESPONDING FIELDS OF TABLE   ITAB
               where erdat in S_ERDop  .
  ELSEIF CB2 EQ 'X' .
     select  * from YDOWNTIME1
       INTO  CORRESPONDING FIELDS OF TABLE   ITAB
       where erdat in S_ERDop and  charg eq p_charg .
  ELSEIF CB3 EQ 'X' .
     select  * from YDOWNTIME1
       INTO  CORRESPONDING FIELDS OF TABLE   ITAB
       where erdat in S_ERDop and charg  eq p_charg and shift eq P_SHIFT .
  ELSEIF  CB4 EQ 'X' .
    select  * from YDOWNTIME1
       INTO  CORRESPONDING FIELDS OF TABLE   ITAB
       where  code eq p_code and  erdat in S_ERDop.
  ELSEIF  CB5 EQ 'X' .
    select  * from YDOWNTIME1
       INTO  CORRESPONDING FIELDS OF TABLE   ITAB
       where  erdat in S_ERDop and EQUNR in S_EQUNR and QMGRP eq p_COGRU.
  ELSEIF  CB6 EQ 'X' .
    select  * from YDOWNTIME1
       INTO  CORRESPONDING FIELDS OF TABLE   ITAB
       where  OPNAME eq p_name and  erdat in S_ERDop.
  ELSEIF   CB7 EQ 'X' .
    select  * from YDOWNTIME1
       INTO  CORRESPONDING FIELDS OF TABLE   ITAB
       where SUPERVISOR eq p_sup and  erdat in S_ERDop.
  ELSEIF   CB8 EQ 'X' .
    select  * from YDOWNTIME1
       INTO  CORRESPONDING FIELDS OF TABLE   ITAB
       where MANG eq p_MANG and  erdat in S_ERDop.
  ELSEIF   CB9 EQ 'X'.
    select  * from YDOWNTIME1
       INTO  CORRESPONDING FIELDS OF TABLE   ITAB
       where erdat in S_ERDop and EQUNR in S_EQUNR.
  endif.
loop at itab.
if itab-schno > 1.
  A = '  '.
  move A to itab-DCOR .
  move A to itab-DCCR .
  move A to itab-DCNR .
  modify itab.
endif.
endloop.
perform create_fieldcat.
data: sort type slis_sortinfo_alv,
      it_sort type  SLIS_T_SORTINFO_ALV.
sort-fieldname = 'EQUNR'.
sort-up = 'X'.
sort-subtot = 'X'.
APPEND sort to it_sort.
sort-fieldname = 'SHIFT'.
sort-up = 'X'.
*sort-subtot = 'X'.
APPEND sort to it_sort.
l_layout-TOTALS_TEXT = 'TOTAL'.
l_layout-SUBTOTALS_TEXT = 'SUBTOTAL'.
   CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
EXPORTING
    i_callback_program       = sy-repid
    is_layout                = l_layout
    it_fieldcat              = gt_fieldcat
    it_events                = it_events
    it_sort                  = it_sort
  TABLES
    T_OUTTAB                       = ITAB
EXCEPTIONS
   PROGRAM_ERROR                  = 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.
*&      Form  CREATE_FIELDCAT
      text
-->  p1        text
<--  p2        text
FORM CREATE_FIELDCAT .
  DATA: LS_FIELDCAT TYPE SLIS_FIELDCAT_ALV.
  CLEAR LS_FIELDCAT.
  LS_FIELDCAT-ROW_POS     = '1'.
  LS_FIELDCAT-COL_POS     = '1'.
  LS_FIELDCAT-FIELDNAME   = 'ERDAT'.
  LS_FIELDCAT-KEY         = ''.
  LS_FIELDCAT-OUTPUTLEN   = '12'.
ls_fieldcat-do_sum       = 'X'.
  LS_FIELDCAT-SELTEXT_L =  'Date'.
  APPEND LS_FIELDCAT TO GT_FIELDCAT.
  clear LS_FIELDCAT .
  CLEAR LS_FIELDCAT.
  LS_FIELDCAT-ROW_POS     = '1'.
  LS_FIELDCAT-COL_POS     = '2'.
  LS_FIELDCAT-FIELDNAME   = 'UZEIT'.
  LS_FIELDCAT-KEY         = ''.
  LS_FIELDCAT-OUTPUTLEN   = '8'.
  LS_FIELDCAT-SELTEXT_L =  'Time'.
  APPEND LS_FIELDCAT TO GT_FIELDCAT.
    clear LS_FIELDCAT .
   CLEAR LS_FIELDCAT.
  LS_FIELDCAT-ROW_POS     = '1'.
  LS_FIELDCAT-COL_POS     = '2'.
  LS_FIELDCAT-FIELDNAME   = 'EQUNR'.
  LS_FIELDCAT-KEY         = ''.
  LS_FIELDCAT-OUTPUTLEN   = '8'.
  LS_FIELDCAT-SELTEXT_L =  'Equipment'.
  APPEND LS_FIELDCAT TO GT_FIELDCAT.
    clear LS_FIELDCAT .
  CLEAR LS_FIELDCAT.
  LS_FIELDCAT-ROW_POS     = '1'.
  LS_FIELDCAT-COL_POS     = '2'.
  LS_FIELDCAT-FIELDNAME   = 'CODE'.
  LS_FIELDCAT-KEY         = ''.
  LS_FIELDCAT-OUTPUTLEN   = '12'.
  LS_FIELDCAT-SELTEXT_L =  'CODE'.
  APPEND LS_FIELDCAT TO GT_FIELDCAT.
    clear LS_FIELDCAT .
  CLEAR LS_FIELDCAT.
  LS_FIELDCAT-ROW_POS     = '1'.
  LS_FIELDCAT-COL_POS     = '3'.
  LS_FIELDCAT-FIELDNAME   = 'QMGRP'.
  LS_FIELDCAT-KEY         = ''.
  LS_FIELDCAT-OUTPUTLEN   = '20'.
  LS_FIELDCAT-SELTEXT_L =  'Code Group'.
  APPEND LS_FIELDCAT TO GT_FIELDCAT.
    clear LS_FIELDCAT .
CLEAR LS_FIELDCAT.
  LS_FIELDCAT-ROW_POS     = '1'.
  LS_FIELDCAT-COL_POS     = '3'.
  LS_FIELDCAT-FIELDNAME   = 'KURZTEXT'.
  LS_FIELDCAT-KEY         = ''.
  LS_FIELDCAT-OUTPUTLEN   = '40'.
  LS_FIELDCAT-SELTEXT_L =  'Code Text'.
  APPEND LS_FIELDCAT TO GT_FIELDCAT.
    clear LS_FIELDCAT .
   CLEAR LS_FIELDCAT.
  LS_FIELDCAT-ROW_POS     = '1'.
  LS_FIELDCAT-COL_POS     = '7'.
  LS_FIELDCAT-FIELDNAME   = 'DCOR'.
  LS_FIELDCAT-KEY         = ''.
  LS_FIELDCAT-OUTPUTLEN   = '14'.
  LS_FIELDCAT-SELTEXT_L =  'Opening Dips'.
  APPEND LS_FIELDCAT TO GT_FIELDCAT.
    clear LS_FIELDCAT .
    CLEAR LS_FIELDCAT.
  LS_FIELDCAT-ROW_POS     = '1'.
  LS_FIELDCAT-COL_POS     = '8'.
  LS_FIELDCAT-FIELDNAME   = 'DCCR'.
  LS_FIELDCAT-KEY         = ''.
  LS_FIELDCAT-OUTPUTLEN   = '14'.
  LS_FIELDCAT-SELTEXT_L =  'Closing Dips'.
  APPEND LS_FIELDCAT TO GT_FIELDCAT.
    clear LS_FIELDCAT .
  CLEAR LS_FIELDCAT.
  LS_FIELDCAT-ROW_POS     = '1'.
  LS_FIELDCAT-COL_POS     = '9'.
  LS_FIELDCAT-FIELDNAME   = 'DCNR'.
  LS_FIELDCAT-KEY         = ''.
  LS_FIELDCAT-OUTPUTLEN   = '10'.
  ls_fieldcat-do_sum       = 'X'.
  LS_FIELDCAT-SELTEXT_L =  'Net Dips'.
  APPEND LS_FIELDCAT TO GT_FIELDCAT.
    clear LS_FIELDCAT .
CLEAR LS_FIELDCAT.
LS_FIELDCAT-ROW_POS     = '1'.
LS_FIELDCAT-COL_POS     = '9'.
LS_FIELDCAT-FIELDNAME   = 'PRO'.
LS_FIELDCAT-KEY         = ''.
LS_FIELDCAT-OUTPUTLEN   = '10'.
ls_fieldcat-do_sum       = 'X'.
LS_FIELDCAT-SELTEXT_L =  'PROD IN LAC'.
APPEND LS_FIELDCAT TO GT_FIELDCAT.
   clear LS_FIELDCAT .
  CLEAR LS_FIELDCAT.
  LS_FIELDCAT-ROW_POS     = '1'.
  LS_FIELDCAT-COL_POS     = '4'.
  LS_FIELDCAT-FIELDNAME   = 'CHARG'.
  LS_FIELDCAT-KEY         = ''.
  LS_FIELDCAT-OUTPUTLEN   = '12'.
  ls_fieldcat-do_sum       = 'X'.
  LS_FIELDCAT-SELTEXT_L =  'Batch Number'.
  APPEND LS_FIELDCAT TO GT_FIELDCAT.
    clear LS_FIELDCAT .
  CLEAR LS_FIELDCAT.
  LS_FIELDCAT-ROW_POS     = '1'.
  LS_FIELDCAT-COL_POS     = '6'.
  LS_FIELDCAT-FIELDNAME   = 'OPNAME'.
  LS_FIELDCAT-KEY         = ''.
  LS_FIELDCAT-OUTPUTLEN   = '20'.
  LS_FIELDCAT-SELTEXT_L =  'Operators Name'.
  APPEND LS_FIELDCAT TO GT_FIELDCAT.
    clear LS_FIELDCAT .
CLEAR LS_FIELDCAT.
  LS_FIELDCAT-ROW_POS     = '1'.
  LS_FIELDCAT-COL_POS     = '6'.
  LS_FIELDCAT-FIELDNAME   = 'SUPERVISOR'.
  LS_FIELDCAT-KEY         = ''.
  LS_FIELDCAT-OUTPUTLEN   = '20'.
  LS_FIELDCAT-SELTEXT_L =  'Supervisor Name'.
  APPEND LS_FIELDCAT TO GT_FIELDCAT.
    clear LS_FIELDCAT .
     CLEAR LS_FIELDCAT.
  LS_FIELDCAT-ROW_POS     = '1'.
  LS_FIELDCAT-COL_POS     = '6'.
  LS_FIELDCAT-FIELDNAME   = 'MANG'.
  LS_FIELDCAT-KEY         = ''.
  LS_FIELDCAT-OUTPUTLEN   = '20'.
  LS_FIELDCAT-SELTEXT_L =  'Manager'.
  APPEND LS_FIELDCAT TO GT_FIELDCAT.
    clear LS_FIELDCAT .
  CLEAR LS_FIELDCAT.
  LS_FIELDCAT-ROW_POS     = '1'.
  LS_FIELDCAT-COL_POS     = '6'.
  LS_FIELDCAT-FIELDNAME   = 'SHIFT'.
  LS_FIELDCAT-KEY         = ''.
  LS_FIELDCAT-OUTPUTLEN   = '20'.
  LS_FIELDCAT-SELTEXT_L =  'Shift'.
  APPEND LS_FIELDCAT TO GT_FIELDCAT.
    clear LS_FIELDCAT .
CLEAR LS_FIELDCAT.
  LS_FIELDCAT-ROW_POS     = '1'.
  LS_FIELDCAT-COL_POS     = '9'.
  LS_FIELDCAT-FIELDNAME   = 'MFSTART'.
  LS_FIELDCAT-KEY         = ''.
  LS_FIELDCAT-OUTPUTLEN   = '10'.
  LS_FIELDCAT-SELTEXT_L =  'Start Time'.
  APPEND LS_FIELDCAT TO GT_FIELDCAT.
    clear LS_FIELDCAT .
   CLEAR LS_FIELDCAT.
  LS_FIELDCAT-ROW_POS     = '1'.
  LS_FIELDCAT-COL_POS     = '9'.
  LS_FIELDCAT-FIELDNAME   = 'MFEND'.
  LS_FIELDCAT-KEY         = ''.
  LS_FIELDCAT-OUTPUTLEN   = '10'.
  LS_FIELDCAT-SELTEXT_L =  'End Time'.
  APPEND LS_FIELDCAT TO GT_FIELDCAT.
    clear LS_FIELDCAT .
   CLEAR LS_FIELDCAT.
  LS_FIELDCAT-ROW_POS     = '1'.
  LS_FIELDCAT-COL_POS     = '9'.
  LS_FIELDCAT-FIELDNAME   = 'DURATION'.
  LS_FIELDCAT-KEY         = ''.
  LS_FIELDCAT-OUTPUTLEN   = '10'.
  ls_fieldcat-do_sum       = 'X'.
  LS_FIELDCAT-SELTEXT_L =  'DURATION'.
  APPEND LS_FIELDCAT TO GT_FIELDCAT.
    clear LS_FIELDCAT .
    CLEAR LS_FIELDCAT.
  LS_FIELDCAT-ROW_POS     = '1'.
  LS_FIELDCAT-COL_POS     = '9'.
  LS_FIELDCAT-FIELDNAME   = 'ZUNIT'.
  LS_FIELDCAT-KEY         = ''.
  LS_FIELDCAT-OUTPUTLEN   = '10'.
  LS_FIELDCAT-SELTEXT_L =  'UNIT'.
  APPEND LS_FIELDCAT TO GT_FIELDCAT.
    clear LS_FIELDCAT .
ENDFORM.                    " CREATE_FIELDCAT
</pre>
Edited by: Matt on Sep 3, 2009 12:06 PM

Similar Messages

  • ALV GRID TEXT in grand Total

    Hi friends,
        In ALV GRID I need to display text in total like grand Total not in subtotal.
    Please let me know the solution .
    Thanks in advance
    Rajendran

    Hi,
    R U using FM or Class.
    If you are using FM, Grand total cannot be produced. Only using classes we can display Grand Totals.
    Its my own experience.
    thanks

  • Currency symbol only for grand total.

    Hi,
    My requirement is i want currency symbol $ only for grand total, all the rows in that column do not have the symbol.
    I need some your help.
    Thank you.

    Although I couldn't understand why you dont want currency format in rows, here is my suggestion.
    Create your report as
    1 dim1.column1 dim2.column2 Measure.Revenue ......... You will get values as below
    1 Value1 Dim2Val1 100
    1 Value2 Dim2Val2 200
    1 Value2 Dim2Val3 300
    UNION
    2 'Grand Total' ' ' Measure.Revenue
    Final result will be as below
    1 Value1 Dim2Val1 100
    1 Value2 Dim2Val2 200
    1 Value2 Dim2Val3 300
    2 Grand Total 600
    Now apply conditional formatting for dim1.column1 in criteria and make the values Bold
    Apply conditional formatting for Measure.Revenue and select Currency in number format.
    Let me know if it was helpful or you were looking for something else.
    Thanks

  • Set specific rows in ALV grid ready for input

    Hi everyone,
      I have a question about how to set specific rows in ALV grid ready for input.
      I know that I can make some columns ready for input before the ALV displayed,but I have no idea how to make specific rows displayed in the ALV ready for input.

    Hello Aaron
    For editable columns we can use the fieldcatalog (LVC_S_FCAT-EDIT = 'X') but for rows you need to define editability on cell level.
    The required steps are documented in sample report BCALV_EDIT_02. Below I point out a few crucial points:
    *§1.Extend your output table for a field, e.g., CELLTAB, that holds
    *   information about the edit status of each cell for the
    *   corresponding row (the table type is SORTED!).
    DATA: BEGIN OF gt_outtab occurs 0.  "with header line
            include structure sflight.
    DATA: celltab type LVC_T_STYL.
    DATA: END OF gt_outtab.
    *§3.Provide the fieldname of the celltab field by using field
    *   STYLEFNAME of the layout structure.
       gs_layout-stylefname = 'CELLTAB'.
       CALL METHOD grid1->set_table_for_first_display
             EXPORTING i_structure_name = 'SFLIGHT'
                       is_layout        = gs_layout
             CHANGING  it_outtab        = gt_outtab[].
    Note: in the sample report only field SEATSMAX is editable. In your case you need
    to fill CELLTAB for all fields in a row.
    *§2.After selecting data, set edit status for each row in a loop
    *   according to field SEATSMAX.
      LOOP AT gt_outtab.
        l_index = sy-tabix.
        refresh lt_celltab.
        if gt_outtab-seatsmax ge 300.
            perform fill_celltab using 'RW'
                                 changing lt_celltab.
        else.
            perform fill_celltab using 'RO'
                                 changing lt_celltab.
        endif.
    *§2c.Copy your celltab to the celltab of the current row of gt_outtab.
        INSERT LINES OF lt_celltab INTO TABLE gt_outtab-celltab.
        MODIFY gt_outtab INDEX l_index.
      ENDLOOP.
    ENDFORM.                               " SELECT_DATA_AND_INIT_STYLE
    NOTE: LVC_T_STYL is a SORTED table type. Thus, take care that you are using the
    INSERT ... INTO TABLE statement and not APPEND (because then nothing is appended
    to the CELLTAB itab).
      IF p_mode EQ 'RW'.
    *§2a.Use attribute CL_GUI_ALV_GRID=>MC_STYLE_ENABLED to set a cell
    *    to status "editable".
        l_mode = cl_gui_alv_grid=>mc_style_enabled.
      ELSE. "p_mode eq 'RO'
    *§2b.Use attribute CL_GUI_ALV_GRID=>MC_STYLE_DISABLED to set a cell
    *    to status "non-editable".
        l_mode = cl_gui_alv_grid=>mc_style_disabled.
      ENDIF.
      ls_celltab-fieldname = 'SEATSMAX'.
      ls_celltab-style = cl_gui_alv_grid=>mc_style_disabled.
      INSERT ls_celltab INTO TABLE pt_celltab.
    Regards
      Uwe

  • Downloads from ALV GRID-Text conversion to dates in EXCEL

    When downloading table displays of data from ALV-GRID for excel spreadsheet, we end of with files that have a header and various line ifnromation.  IF we manually clear up the display, then we can have the individicual column headers used and force them to text but if we just call the file up as an EXCEL spreadsheet, some part numbers such 12-3465 appear in Excel as Dec-65.
    The following is an example of the record (but it is word wrapped within this display limit).  In actuality, the verbage enclosed with the <b> represent the start of the  lines that have actual display data running out about 90 characters.
    Suggestions on how to make the download immediately correct in Excel direct from SAP ALV-GRID without cleaning out the heading lines and manually forcing the affected columns to TEXT format?
    thanks
    <b>03/02/2007</b>                                                                    Dynamic List Display                                                                                1
    <b>Materials-Inforecord Details Report</b>
    <b>Purchasing Org: ILMO</b>
                        <b>Report Run Date:03/02/2007</b>                    <b>Report Time:14:31:16</b>
         <b>Plnt     Mat Grp     Vendor     Name 1     Material     Material</b> description     Vendor Cat     Mfr     MPN     PC     Item Chg.     OUn      Eq to     BUn     Net price     Per     OPUn     Inforecord     PGr     Mv Avg        per     ValCl
         <b>0042     04     106070     BURROWS COMPANY</b>     184110     Glv Exam Ltx Non Ster     02-5001     TILLOTSON     02-5001               CA     2,000     EA        93.40      1     CA     5300006999     999     93.40     2,000     6438

    there are different options to export to excel which all behave differently, if you go for the menu ->export it differs from the export button from the alv buttonbar.
    try the different export to excel options perhaps there is one that behaves the way you want
    kind regards
    arthur de smidt

  • ALV Grid throwing dump in total function

    Hi,
      My ALV grid program, is working fine in development server, for the total and subtotal function. However, the same program is throwing a short dump in Quality server when we try to get the total.Please help!
    Regards,
    Anita Jeyan

    Hi ,
    Please go to ST22 and check what is the reason for error.
    Let me know the error.
    The reason might be due to some less data size or some data type mismatch.
    Regards,
    Uma
    Edited by: UmaDave on Jun 9, 2010 12:10 PM
    Edited by: UmaDave on Jun 9, 2010 12:10 PM

  • Validating in ALV grid output for double entry

    Hi All,
             I am trying to validate the ALV output while adding records to the screen.
    I need to validate if the same primary key exist while user is creating a new record in the ALV output. If the same record is entered many time ( with the same primary key), it should pop up some error and i am calling
    call method pr_data_changed->add_protocol_entry.
    But i'm not able to apply the logic for 2 fields as primary key.
    I check the method check_double_entry in program BCALV_EDIT_04. it does the same but it checks i field 'FLDATE' as primary key.
    Algorithm: Copy all entries in MT_GOOD_CELLS to a dummy table.
               During the copying procedure check if there exists
               already a line with the same Flight date.
        loop at pr_data_changed->mt_good_cells into ls_good.
          case ls_good-fieldname.
            when 'FLDATE'.
              call method pr_data_changed->get_cell_value
                          exporting
                                i_row_id = ls_good-row_id
                                i_fieldname = ls_good-fieldname
                          importing e_value = l_flightdate.
              read table lt_good_cells with key
                                value = l_flightdate
                                transporting no fields.
              if sy-subrc = 0.
    There exists already a line with the same flight date!
                call method pr_data_changed->add_protocol_entry
                             exporting
                  i_msgid = '0K' i_msgno = '000'  i_msgty = 'E'
                  i_msgv1 = text-m01
                  i_fieldname = ls_good-fieldname
                  i_row_id = ls_good-row_id.
                error_in_data = 'X'.
              else.
                ls_good-value = l_flightdate.
                append ls_good to lt_good_cells.
              endif.
          endcase.
        endloop.
    Could you pls help me how to use this logic in case where more than 1 field is primary key.
    Regards,
    Santos P

    Hi
    ALV option is available from 4.7 onwards only.
    the following needs to be followed in 4.7 to get in ALV:
    We can get the results in ALV format just by changing the IMG settings.
    Go to IMG under Materials Management -> Purchasing ->Reporting -> Maintain Purchasing Lists -> Scope of List -> Define Scope of List. Select any one option & double click. A new screen will display with lot of check boxes. in the end will find a check box for "Settings for ALV grid control. Just tick that box & save this as new name like BEST_ALV.
    regards
    Srinivas

  • ALV Report - Average and Grand total.

    Hi,
    Could you tell me in ALV, how i can calculate the average of a particular field and display it in the grand total row?
    What is the property to display the grand total alone, without the subtotal?

    To force a grand total line, first you need to have a field in your internal table that can be totaled, when defining that field in your field catalog, you must set the flag for DO_SUM = 'X',  you may also need to set the DATATYPE = 'QUAN'.  Then the grand total line will show automatically.
    Regards,
    RIch Heilman

  • Valid Scrypt for Grand Total

    I have created an expanding table, using the following link:
    http://forms.stefcameron.com/2009/02/25/expandable-table-with-totals/
    (instructions shown below)
    However, I have been unsuccessful with the Grand Total value. As shown in the picture below, the rest of the totals show but the Grand Total remains blank. I must include the Installation fee (marked by the check box)
    This is the last step needed to complete my form, I would really appreciate all the help i can receive.
    Thank you!

    Row1[x] (where x is an integer) is the name and subscript for your rows. In the example, Stef (if that's his real name) used Item as the name for his rows. In your form, you are using Row1. So, each row is named Row1[0], Row1[1], Row1[2], etc... Inside of each Row1, you have a text field called "Total." Since you're using formCalc, you are summing the total of those rows using Row1[*].Total. So, if you haven't changed anything else, you should (at the very least) be able to sum the rows in the grand total box using
    $.rawValue = Sum(Row1[*].Total)
    Now, the checkbox is a different story. The checkbox has an "on" value and an "off" value. We can use that in formCalc to more easily add it to the value that we're going to get for the grand total. If you set the "on" value to 300 (I included an illustration of that in my first picture), then you can use the name of the checkbox to get your total. If the checkbox is checked or "on", then the on value (300 in my example) gets added to the total, and if it's unchecked or "off", then the off value (0 in my example) gets added. The checkbox also has to have it's name correct. In my example it's called CheckBox1, in your code you have Installation. So, whatever you named the checkbox needs to go at the end of the formula we're using like so.
    $.rawValue = Sum(Row1[*].Total) + Installation
    If you named your checkbox something else, then you'll need to change the word "Installation" to whatever the checkbox is named. (The name is in the hierarchy tree.)

  • Highlight the column in the ALV grid only for few entries!

    Hi all,
    I am using the FM "REUSE_ALV_GRID_DISPLAY" to dsplay the o/p of my report in ALV grid.
    Now i need to highlight 1 particluar column for only some entries(row) based on the value of the column which is to be highlighted.
    Can anyone tell me the steps to do so??

    Please make search thru this form you can find lot of threads
    For example
    https://forums.sdn.sap.com/search.jspa?threadID=&q=alvANDcellANDcolor+&objID=f50&dateRange=all&numResults=15

  • ALV Grid: event for user return in ALV Grid Control

    Hi developers,
    i'm wanna do something after a user has pressed the return button in a alv grid control. For that i need probably a event. But i can not find a proper event in the documentation. Could one of you guys help me?
    Best regards christian

    Hi Christian
    ALV grid is an encapsulated object, so it seems there is no way, you ought to implement the data_changed event. So if you want to make bulk data input and after trigger the event by pressing the return key, you should make the ALV Grid get your changes after pressing the key but not after a cell change of a modified cell.
    To set this attribute:
    CALL METHOD gr_alvgrid->register_edit_event
         EXPORTING i_event_id = cl_gui_alv_grid=>mc_evt_enter .
    This way "data_changed" event will be triggered whenever you press the return key while editing.
    For some more information you can also refer to the tutorial <a href="https://www.sdn.sap.comhttp://www.sdn.sap.comhttp://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/documents/a1-8-4/an%20easy%20reference%20for%20alv%20grid%20control.pdf">"An Easy Reference for ALV Grid Control"</a>.
    Regards
    *--Serdar <a href="https://www.sdn.sap.com:443http://www.sdn.sap.comhttp://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.sdn.businesscard.sdnbusinesscard?u=qbk%2bsag%2bjiw%3d">[ BC ]</a>

  • ALV Grid: event for return

    Hi developers,
    i'm wanna do something after a user has pressed the return button in a alv grid control. For that i need probably a event. But i can not find a proper event in the documentation. Could one of you guys help me?
    Best regards christian

    You should post your question in the ABAP forum

  • *urgent* Alternate colors for Grand total values

    Hi all,
    I have 1 dimension column and 4 fact columns. Here I perform Grand total for the request .
    The requirement is :---
    I need alternate colors as background for the Grand total values.
    Am trying to modify the XML in Advanced tab .
    I tried to do it by using combine request .
    Please help on this . Urgent .
    Thanks a lot in advance for every reply .

    Please give some suggestions.

  • Alternating colors for grand total  values

    hii
    i hve a requirement that grandtotal values should be displayed in alternate colors..actualy grand total values be in blue..bt i need the alternate colors for the values of grand total..pls help me regarding this..

    Please give some suggestions.

  • ALV Grid Display for ME2N, ME2L

    Hello,
    We have a requirement where we want the ALVGrid Display for ME2N, ME2L. When we list these in excel file it comes in very scattered manner.
    Client is looking for PO report similar to ME80FN with credit terms, GR Info etc.. I believe ECC 6.0 have ALV Grid in standard, else this can be incorporated thru OLME --- > Reporting ---> Scope of List and does not require query but I am not sure how to achieve it.
    Regards,
    Puneet

    Puneet,
    In the selection screen of ME2N or ME2L, if you will select ALV in the field SCOPE OF LIST, u will get the report in ALV format.
    To default the SCOPE OF LIST in any transaction code from BEST to ALV, please follow the below path in SPRO:
    Materials ManagementPurchasing-Reporting-Maintain Purchasing Lists-Scope of List---Define Default Values for Transactions

Maybe you are looking for

  • Error message "F" using Menu Builder

    I have created two movies, saved them as .cp files and also exported them as EXE files. I inserted the the EXE versions as Items into a MenuBuilder project. I save that project as an .mpg file and exported it as an EXE file as well. What I wanted to

  • Front audio connector

    Hi there!  I have the 845E Max motherboard, and my case has a front audio coonection in it.  I was jsut wondering  if it is possible to connect the front without disabling the back audio panel.  thx....

  • OpenSSH 4.4p1 packages with PAM support for Solaris 9, 10

    As mentioned in a previous post* , I've compiled OpenSSH packages with PAM support for Solaris 9 and 10. They've since been updated to version 4.4p1, and are compiled against a static zlib (1.2.3) and OpenSSL (0.9.8c). You can find them here: http://

  • Uninstall/Install. . .Help!

    I Uninstalled Indesign because I was having too many issues. In my cloud app manager it still appears as though I have it.  So I went to the Adobe website in an attempt to reinstall and it won't. Can anyone help?

  • Creation PO in classic scenario in backend

    Hi, I'm in classic scenario with plan driven. I'm using SRM 5.5 I'm using bid engine and i'd like to create a PO in backend directly from a bid. What do I need to get it? thanks in advance Best Regards