Skip to Content
author's profile photo Former Member
Former Member

ALV Subtoals Color display problem


I have done changes for a standard program.

i have to display the subtotals with custom logic for 'List Dispay' and 'Hierarchi display'.

I done the subtotal calculation part and pussing one empty row with subrotals value in the final internal table.

its displaying correctly in the output. But i am getting 2 problem in the ourput.

1. In the Subtotal row color yellow i am displaying, but this color is not displaying for the Kay fields.

The color for the key fields is displaying as the item key fields.

i want same color in the entire row.for a particular record, How to get this?

2. I am appending subtotal row as a record in the final internal table, in the ALV output there is button 'List Status' with

Information button . when clicks on this button its showing the total records display in the list.

but its counting the Subtotal row as a record. i dont want to display this record in the 'List Status'

Ex : It line item have one record, it should show : 1

but it is showing : 2.

its counting the Subtotal record as a record.

Please provide the available solutions for the above problem ASAP.

Thanks in Advance.

Add comment
10|10000 characters needed characters exceeded

1 Answer

  • author's profile photo Former Member
    Former Member
    Posted on Jul 14, 2009 at 08:40 AM


    1. To implement your own color to key fields, first remove the key for those columns in Fieldcat settings.

    in fieldcat there is option called 'KEY' ( column with key-color), set this field to space so it will not consider that field as Key.

    2. for totals, manually count the number of lines in the internal table instead of DESCRIBE . when you are appending the subtotal line into internal table don't count that field. so, you will get the exact number of lines .



    Add comment
    10|10000 characters needed characters exceeded

    • Former Member


      Thanks for ur reply.

      1. Solved

      2. System taking this count from SAP Standard program.

      I dont have controll to change the Count.

      Please provide any possible answer for this.

      Thanks in Advance.