Skip to Content
0
Former Member
Feb 20, 2009 at 11:41 AM

ALV Grid Display - Dump when exporting (via right click)

139 Views

Hi,

We have an ALV filled with a dynamic table because we needed dynamic columns. Our ALV has totals and subtotals. When exporting ALV via right click I get the following error:

OBJECTS_OBJREF_NOT_ASSIGNED

I observed two facts:

1.- If I disable subtotals and totals (commentig wa_cat-do_sum = 'X') export works properly, otherwise I get the dump.

2.- Having totals and subtotals enabled, if I use export icon (top toolbar) the export works properly, but using right-click export gets the same dump.

Our fieldcat is like this:

...
    CLEAR wa_cat.
    wa_cat-fieldname = g_cols.
    wa_cat-seltext_s = gi_subdiv-btrtl.
    wa_cat-seltext_l =  gi_subdiv-btrtl.
    wa_cat-datatype = 'INT4'. 
    wa_cat-do_sum = 'X'.
    wa_cat-outputlen = '6'.
    APPEND wa_cat TO fs_fldcat.
...

and we call ALV:

* Call ABAP List Viewer (ALV)
  CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
    EXPORTING
      it_fieldcat            = fs_fldcat
      i_callback_program     = v_repid
      is_layout              = s_layout
      i_callback_user_command  = 'USER_COMMAND'
      it_sort                = t_sort
*      i_callback_top_of_page = 'F_TOP_OF_PAGE'
      i_save                 = 'X'
    TABLES
      t_outtab               = <t_dyntable>.

Any help will be appreciated!

Thanks,

Josep