Skip to Content
avatar image
Former Member

ALV Grid printing problem

Dear All,

I have developed a ALV report in grid and sorted two fields in tht. but whn i am taking print of tht the sorted cloumns also printing each and every line.

For ex:-

the cloumn is BANK name : SBI and it has 10 records

in display it is showing SBI only once but when printing it is printing 10 times.

Can we sort ALV list also and how?

Add comment
10|10000 characters needed characters exceeded

  • Follow
  • Get RSS Feed

3 Answers

  • avatar image
    Former Member
    Sep 01, 2008 at 06:07 AM
    Add comment
    10|10000 characters needed characters exceeded

  • Sep 01, 2008 at 06:10 AM

    >in display it is showing SBI only once but when printing it is >printing 10 times.

    While printing it won't consider the Sort , so it will print all the value. If you want to make some separation then you can group by page. all Gorup will be printed together in one page.

    sort-group = '*'. "<----Page.

    I hope you are using sort functionality already.

    Add comment
    10|10000 characters needed characters exceeded

    • you mean you are already populating the sort table and passing it to ALV.

      Any way Sort will work in print , but you cannot avoid that Repeatable value in print.

      if you want you can differenitiate them by Triggering a new page.

      SORT-FIELDNAME = 'COLUMNANME'.
      SORT-UP  = 'X'.
      SORT-GROUP = '*' . "For new page
      APPEND SORT TO IT_SORT.

  • avatar image
    Former Member
    Sep 01, 2008 at 06:12 AM

    hi,

    Refer to the link.

    www.sap Technical.com ->Tutorials >ALV/PageNumbers/Demo.htm

    Regards

    Sumit Agarwal

    Add comment
    10|10000 characters needed characters exceeded