10-15-2008 5:36 PM
Hi All,
Can any body explain how to create a dynamic internal table with deep structure.
I am using GRID Display for the output based upon the entries in the Dynamic Internal Table.
I have 10 rows fixed in my output, but where as the coloumns get changed dynamically, Now i have to display the 5th row and the 10th row in Bold in the output.
For this I need to use the stucute lvc_s_Styl , but i am not able to create the dynamic internal table for this by passing the lvc_s_styl into the dynamic fieldcat structure lvc_s_fcat.
Can anyone help me in this..?
Thanks,
Rajesh
10-15-2008 5:41 PM
You can check this post on how to create Dynamic Internal Table:
http://help-abap.blogspot.com/2008/09/dynamic-internal-table-creation.html
It also shows how to use the CL_SALV_TABLE to generate the output.
Regards,
Naimesh Patel
10-15-2008 5:55 PM
Hi ,
this is fine, but my requirement is to create a dynamic internal table with coloumn as
deep strucuture table type lvc_t_styl.
10-15-2008 7:08 PM
Ok.. I didn't get that before.
To create a table with a table type LVC_T_STYL you have to:
Get the table description
Create a field with that table description
DATA: lo_tab TYPE REF TO cl_abap_tabledescr.
lo_tab ?= cl_abap_typedescr=>describe_by_name( 'LVC_T_STYL' ).
* Field name
la_comp-name = 'STYLE_TAB'.
*
* Field type
la_comp-type = lo_tab.
* Filling the component table
APPEND la_comp TO lt_tot_comp.
CLEAR: la_comp.
In the continuation to the example given in the previous post, you can enter this piece of code after the DO .. ENDDO and before the step 3: Create a new Type.
Regards,
Naimesh Patel
10-15-2008 7:34 PM