Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

header in alv grid using class

Former Member
0 Likes
1,039

Hello All,

I developed alv grid using class method.

First I created CREATE OBJECT GR_CCONTAINER

then CREATE OBJECT GR_ALVGRID

then PERFORM FIELD_CATALOG TABLES GT_FIELDCAT----


for field catalog

PERFORM LAYOUT CHANGING GS_LAYOUT.----


for header

p_gs_layout-grid_title = 'class method'.

p_gs_layout-sel_mode = 'D'.

APPEND P_GS_LAYOUT TO IT_LAYOUT.

and finally CALL METHOD GR_ALVGRID->SET_TABLE_FOR_FIRST_DISPLAY

the report is cooming fine but in header it comes only "class method".

but i need also

1. reporting date

2. reporting time.

can any body tell me how i can i put 2 more heading line

Thanks,

Rakesh

Hello All,

I developed alv grid using class method.

First I created CREATE OBJECT GR_CCONTAINER

then CREATE OBJECT GR_ALVGRID

then PERFORM FIELD_CATALOG TABLES GT_FIELDCAT----


for field catalog

PERFORM LAYOUT CHANGING GS_LAYOUT.----


for header

p_gs_layout-grid_title = 'class method'.

p_gs_layout-sel_mode = 'D'.

APPEND P_GS_LAYOUT TO IT_LAYOUT.

and finally CALL METHOD GR_ALVGRID->SET_TABLE_FOR_FIRST_DISPLAY

the report is cooming fine but in header it comes only "class method".

but i need also

1. reporting date

2. reporting time.

can any body tell me how i can i put 2 more heading line

Thanks,

Rakesh

3 REPLIES 3
Read only

Former Member
0 Likes
657

Hi,

try giving all three in the Gridtitle.

w_lay-grid_title = 'Classmethod Reporting date Reporting Time'.

Read only

Former Member
0 Likes
657

Hi Dude,

Please refer the below link how to handle the header in alv using abap oo

https://www.sdn.sap.com/irj/scn/wiki?path=/display/snippets/abapObjects-ALVModel-UsingHeaderand+Footer

Hope it clears,..............

Thanks & Regards

Ramakrishna Pathi

Read only

I355602
Product and Topic Expert
Product and Topic Expert
0 Likes
657

Hi,

Refer:-

Hope this helps you.

Regards,

Tarun