in the final display list how can i change rows to columns
and vice versa
Answer Posted / vrushali
This is possible using dynamic internal table.
Declaration
DATA : IFCAT_TAB TYPE LVC_T_FCAT,
FCAT_TAB TYPE LVC_S_FCAT.
DATA : TLINS TYPE I.
FIELD-SYMBOLS : <LIST> TYPE TABLE, <L_LINE> TYPE ANY.
FIELD-SYMBOLS : <FVAL> TYPE ANY, <FPOV> TYPE ANY,
<TFVAL> TYPE ANY.
DATA : IDATA TYPE REF TO DATA,
NEW_LINE TYPE REF TO DATA.
LOOP AT ALV_FLDCAT_T INTO ALV_FLDCAT.
MOVE-CORRESPONDING ALV_FLDCAT TO FCAT_TAB.
APPEND FCAT_TAB TO IFCAT_TAB.
ENDLOOP.
After creating normal alv field catalogue we can add rows
info as column....
DELETE ADJACENT DUPLICATES FROM IFCAT_TAB COMPARING
FIELDNAME.
SORT IFCAT_TAB BY COL_POS ASCENDING. "FIELDNAME
CALL METHOD CL_ALV_TABLE_CREATE=>CREATE_DYNAMIC_TABLE
EXPORTING
IT_FIELDCATALOG = IFCAT_TAB
IMPORTING
EP_TABLE = IDATA.
ASSIGN IDATA->* TO <LIST>.
CREATE DATA NEW_LINE LIKE LINE OF <LIST>.
ASSIGN NEW_LINE->* TO <L_LINE>.
Is This Answer Correct ? | 2 Yes | 0 No |
Post New Answer View All Answers
I created a field and entered the field type, when I double clicked the field type to define the domain; it is asking for an ACCESS KEY, I am not changing any SAP defined tables, working on a user defined table.
Can we access static attribute from instance method
What is Field group?
In events, start-of-selection is a default event. When we have to use this event explicitly? Why?
How to get that a secondary index is attached to a select query?
What are logical data bases used in hr module? : abap hr
What is the difference between open_form and close_form?
How many default tab strips are there?
What is the difference between Classic badi and Kernal badi ?
How to know if the value entered contains records or not?
In which particular scenario we use sorted table and which particular scenario we use standard table?
What is dialog module?
What are the 3 types of tables in sap? : abap data dictionary
Explain the components of selection table?
I am trying to automate a manual processing of iDOCs in BD87. I used the following code to pass idoc-id to global variable 'DCN' and then skip the first screen of BD87 to go to processing directly. After running this code SET PARAMETER ID 'DCN' FIELD itabhdr-idoc_id. CALL TRANSACTION 'BD87' AND SKIP FIRST SCREEN. it takes me to the first screen because it cannot recognize my idoc-id. How I can pass idoc-id to global? I have used the above code to goto VA02 with VBELN and it worked perfectly.