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

ALV Title

Former Member
0 Likes
663

Hi all,

Donot use Reuse_alv_grid_display.

use Call method.. see below it..

data : it_title type lvc_title value 'User List'.

call method w_alv_grid->set_table_for_first_display

exporting

is_layout = is_layout

changing

it_outtab = IT_EMP

it_fieldcatalog = it_fieldcat

it_title = it_title------> Error Statement

exceptions

invalid_parameter_combination = 1

program_error = 2

too_many_lines = 3

others = 4.

How is the correct program..?

Reply me soon,

thx,

s.suresh

1 ACCEPTED SOLUTION
Read only

RaymondGiuseppi
Active Contributor
0 Likes
616

The title is part of the layout parameter :

DATA: is_layout TYPE lvc_s_layo,
    (...)
    is_layout-grid_title = text-101.
    CALL METHOD grid0101->set_table_for_first_display
      EXPORTING
        (...)
        is_layout = is_layout
        (...)

Regards

4 REPLIES 4
Read only

Former Member
0 Likes
616

Hi,

Please refer to the SAP standard demo program BCALV_TEST_HEADER.

Thanks,

Sriram POnna.

Read only

Former Member
0 Likes
616

hi,

Declare a variable type of LVC_TITLE, you can pass the value to it and pass the variable to i_grid_title of ALV.

Also,

why u r specifying that in quotes.. 'tstct-ttext' .. give it like this.. tstct-ttext. Also check whether data is there in that field or not.

hope this helps.

regs,

Hema.

Read only

RaymondGiuseppi
Active Contributor
0 Likes
617

The title is part of the layout parameter :

DATA: is_layout TYPE lvc_s_layo,
    (...)
    is_layout-grid_title = text-101.
    CALL METHOD grid0101->set_table_for_first_display
      EXPORTING
        (...)
        is_layout = is_layout
        (...)

Regards

Read only

Former Member
0 Likes
616

hi,


DATA:LV_TITLE TYPE LVC_S_LAYO-GRID_TITLE.


LV_TITLE = 'Summary Report'.

WA_LAYOUT-GRID_TITLE = LV_TITLE.

        CALL METHOD O_GRID_DATA->SET_TABLE_FOR_FIRST_DISPLAY
          EXPORTING
            IS_LAYOUT       = WA_LAYOUT
            I_SAVE          = 'A'
            IS_VARIANT      = LS_VARIANT
          CHANGING
            IT_OUTTAB       = IT_COUNT
            IT_FIELDCATALOG = IT_FLDCAT
            IT_SORT         = IT_SORT.
*         IT_FILTER                     =
        IF SY-SUBRC <> 0.
*      MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
*                 WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
        ENDIF.