<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: ALV header problem in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/alv-header-problem/m-p/3616653#M871287</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Supply a different Subroutine to the ALV FM's....in the parameter&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I_CALLBACK_TOP_OF_PAGE&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Santhosh&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 02 Apr 2008 14:32:43 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2008-04-02T14:32:43Z</dc:date>
    <item>
      <title>ALV header problem</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/alv-header-problem/m-p/3616651#M871285</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi all,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am facing problem when tried to display header in alv.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have One basic Alv report clicking on particular record corresponding data containing another ALV report displays .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Now i want to change the header text info for primary ALV  and secondary ALV.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any suggestion welcome.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 02 Apr 2008 14:25:57 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/alv-header-problem/m-p/3616651#M871285</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-04-02T14:25:57Z</dc:date>
    </item>
    <item>
      <title>Re: ALV header problem</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/alv-header-problem/m-p/3616652#M871286</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Do you mean you want to change the column headers ? That can be done by changing the fieldcatalog, attribute COLTEXT.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;kr,&lt;/P&gt;&lt;P&gt;Peter&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 02 Apr 2008 14:32:11 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/alv-header-problem/m-p/3616652#M871286</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-04-02T14:32:11Z</dc:date>
    </item>
    <item>
      <title>Re: ALV header problem</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/alv-header-problem/m-p/3616653#M871287</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Supply a different Subroutine to the ALV FM's....in the parameter&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I_CALLBACK_TOP_OF_PAGE&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Santhosh&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 02 Apr 2008 14:32:43 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/alv-header-problem/m-p/3616653#M871287</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-04-02T14:32:43Z</dc:date>
    </item>
    <item>
      <title>Re: ALV header problem</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/alv-header-problem/m-p/3616654#M871288</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks for quick reply,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;i am using that FM just it displays blank and some space is showing for that.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 02 Apr 2008 14:38:05 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/alv-header-problem/m-p/3616654#M871288</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-04-02T14:38:05Z</dc:date>
    </item>
    <item>
      <title>Re: ALV header problem</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/alv-header-problem/m-p/3616655#M871289</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;No i want to change the header text and some colulmns too.&lt;/P&gt;&lt;P&gt;I need solution for header text.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 02 Apr 2008 14:39:21 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/alv-header-problem/m-p/3616655#M871289</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-04-02T14:39:21Z</dc:date>
    </item>
    <item>
      <title>Re: ALV header problem</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/alv-header-problem/m-p/3616656#M871290</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I mean this&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Primary ALV&lt;/P&gt;&lt;P&gt;form display_alv_report.&lt;/P&gt;&lt;P&gt;  gd_repid = sy-repid.&lt;/P&gt;&lt;P&gt;  call function 'REUSE_ALV_GRID_DISPLAY'&lt;/P&gt;&lt;P&gt;       exporting&lt;/P&gt;&lt;P&gt;            i_callback_program      = gd_repid&lt;/P&gt;&lt;P&gt;            i_callback_top_of_page   = 'TOP_OF_PAGE'  "see FORM&lt;/P&gt;&lt;P&gt;            i_callback_user_command = 'USER_COMMAND'&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;           i_grid_title           = outtext&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;            is_layout               = gd_layout&lt;/P&gt;&lt;P&gt;            it_fieldcat             = fieldcatalog[]&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;           it_special_groups       = gd_tabgroup&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;            it_events               = gt_events&lt;/P&gt;&lt;P&gt;            is_print                = gd_prntparams&lt;/P&gt;&lt;P&gt;            i_save                  = 'X'&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;           is_variant              = z_template&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;       tables&lt;/P&gt;&lt;P&gt;            t_outtab                = it_ekko&lt;/P&gt;&lt;P&gt;       exceptions&lt;/P&gt;&lt;P&gt;            program_error           = 1&lt;/P&gt;&lt;P&gt;            others                  = 2.&lt;/P&gt;&lt;P&gt;  if sy-subrc &amp;lt;&amp;gt; 0.&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;        WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Second ALV&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;form display_alv_report.&lt;/P&gt;&lt;P&gt;  gd_repid = sy-repid.&lt;/P&gt;&lt;P&gt;  call function 'REUSE_ALV_GRID_DISPLAY'&lt;/P&gt;&lt;P&gt;       exporting&lt;/P&gt;&lt;P&gt;            i_callback_program      = gd_repid&lt;/P&gt;&lt;P&gt;            i_callback_top_of_page   = 'TOP_OF_PAGE2'  "see FORM&lt;/P&gt;&lt;P&gt;            i_callback_user_command = 'USER_COMMAND'&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;           i_grid_title           = outtext&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;            is_layout               = gd_layout&lt;/P&gt;&lt;P&gt;            it_fieldcat             = fieldcatalog[]&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;           it_special_groups       = gd_tabgroup&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;            it_events               = gt_events&lt;/P&gt;&lt;P&gt;            is_print                = gd_prntparams&lt;/P&gt;&lt;P&gt;            i_save                  = 'X'&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;           is_variant              = z_template&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;       tables&lt;/P&gt;&lt;P&gt;            t_outtab                = it_ekko&lt;/P&gt;&lt;P&gt;       exceptions&lt;/P&gt;&lt;P&gt;            program_error           = 1&lt;/P&gt;&lt;P&gt;            others                  = 2.&lt;/P&gt;&lt;P&gt;  if sy-subrc &amp;lt;&amp;gt; 0.&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;        WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Form TOP_OF_PAGE.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;use Fm REUSE_ALV_COMMENTARY_WRITE here&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;EndForm.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Form TOP_OF_PAGE2.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;use Fm REUSE_ALV_COMMENTARY_WRITE here&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;EndForm.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This will work.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;santhosh&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 02 Apr 2008 14:44:07 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/alv-header-problem/m-p/3616656#M871290</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-04-02T14:44:07Z</dc:date>
    </item>
    <item>
      <title>Re: ALV header problem</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/alv-header-problem/m-p/3616657#M871291</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;SPAN __default_attr="blue" __jive_macro_name="color"&gt;
Navdeep singh,
Just follow these steps
1.
Define 2 events internal tables for 2 output as u r not using same Header text for 2 ALV outputs
data :
&lt;PRE&gt;&lt;CODE&gt;i_events_p  type slis_t_event, "Primary ALV
i_events_s  type slis_t_event, "for Secondary ALV
w_events  like line of i_events.&lt;/CODE&gt;&lt;/PRE&gt;
2.
Build events table .
&lt;PRE&gt;&lt;CODE&gt;w_events-name = 'TOP_OF_PAGE' .
w_events-form   = 'TOP_OF_PAGE_P' .
append w_events to i_events_p.
clear w_events.&lt;/CODE&gt;&lt;/PRE&gt;

&lt;PRE&gt;&lt;CODE&gt;w_events-name = 'TOP_OF_PAGE' .
w_events-form   = 'TOP_OF_PAGE_S' .
append w_events to i_events_s.
clear w_events.&lt;/CODE&gt;&lt;/PRE&gt;
3.
pass this events tables through REUSE_ALV_GRID_DISPLAY in Primary ans Secondary.
4.
Callback subroutines for TOP_OF_PAGE event.
&lt;PRE&gt;&lt;CODE&gt;*&amp;amp;---------------------------------------------------------------------*
*&amp;amp;      Form  top_of_page
*&amp;amp;---------------------------------------------------------------------*
FORM top_of_page_p.
 
  DATA :
   li_header TYPE slis_t_listheader,
   w_header  LIKE LINE OF li_header.
 
  w_header-typ  = 'S'.
  w_header-info = 'XYZ Pte Ltd'.
  APPEND w_header TO li_header.
  CLEAR w_header.
 
  w_header-typ  = 'H'.
  w_header-info = sy-repid.
  APPEND w_header TO li_header.
  CLEAR w_header.
 
  w_header-typ  = 'A'.
  w_header-info = sy-title.
  APPEND w_header TO li_header.
  CLEAR w_header.
 
  CALL FUNCTION 'REUSE_ALV_COMMENTARY_WRITE'
    EXPORTING
      it_list_commentary = li_header.
endform.&lt;/CODE&gt;&lt;/PRE&gt;
&lt;PRE&gt;&lt;CODE&gt;*&amp;amp;---------------------------------------------------------------------*
*&amp;amp;      Form  top_of_page
*&amp;amp;---------------------------------------------------------------------*
FORM top_of_page_s.
 
  DATA :
   li_header TYPE slis_t_listheader,
   w_header  LIKE LINE OF li_header.
 
  w_header-typ  = 'S'.
  w_header-info = 'XYZ Pte Ltd'.
  APPEND w_header TO li_header.
  CLEAR w_header.
 
  w_header-typ  = 'H'.
  w_header-info = sy-repid.
  APPEND w_header TO li_header.
  CLEAR w_header.
 
  w_header-typ  = 'A'.
  w_header-info = sy-title.
  APPEND w_header TO li_header.
  CLEAR w_header.
 
  CALL FUNCTION 'REUSE_ALV_COMMENTARY_WRITE'
    EXPORTING
      it_list_commentary = li_header.
endform.&lt;/CODE&gt;&lt;/PRE&gt;
5.
If you want to change the Columns text manually.build fieldcatalog manually or set text for the field using seltext_m or seltext_l or seltext_s in the fieldcatalog internal table.
check below.
  &lt;PRE&gt;&lt;CODE&gt;w_fieldcat-fieldname = 'ENAME'.
  w_fieldcat-tabname   = 'I_PA0001'.
  w_fieldcat-seltext_m = 'Employee Name'.
  append w_fieldcat to i_fieldcat.
  clear w_fieldcat.&lt;/CODE&gt;&lt;/PRE&gt;

I hope that it helps you.
&lt;STRONG&gt;Regards,&lt;/STRONG&gt;
&lt;STRONG&gt;Venkat.O&lt;/STRONG&gt;
&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 03 Apr 2008 07:26:06 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/alv-header-problem/m-p/3616657#M871291</guid>
      <dc:creator>venkat_o</dc:creator>
      <dc:date>2008-04-03T07:26:06Z</dc:date>
    </item>
  </channel>
</rss>

