Is it possible to export two alv grids to one spreadsheet?
Hi All!
I need to export two grids to one spreadsheet. Is it possible using standard functionality?
It looks like i need to develop my own export function.
Please advise.
Many thanks!
Hi,
If you bolock list ALV display, then it is possible.
If not, then you need to add one button on the application toolbar, in user command portion u need to write code for exporting the data to spreadshee either using OLE functionality or using GUI download like below ....
data : lv_append TYPE char01, "Append indicator
lv_tabdl TYPE char01, "Tab indicator
lv_tabdl = cl_abap_char_utilities=>horizontal_tab.
" d/l the first table
CALL FUNCTION 'GUI_DOWNLOAD'
EXPORTING
filename = lv_fname
write_field_separator = lv_tabdl
TABLES
data_tab = l_it_hdr
EXCEPTIONS
file_write_error = 1
no_batch = 2
OTHERS = 3.
IF sy-subrc <> 0.
" Error message
ENDIF.
" d/l the second table
lv_append = c_check.
CALL FUNCTION 'GUI_DOWNLOAD'
EXPORTING
filename = lv_fname
write_field_separator = lv_tabdl
append = lv_append
TABLES
data_tab = g_it_op_a
EXCEPTIONS
file_write_error = 1
no_batch = 2
OTHERS = 3.
IF sy-subrc <> 0.
" Error message
ENDIF.
Regards,
Amitava
Similar Messages
-
How can I get the selected rows from two ALV grids at the same time?
I have a program that uses two ALV grids in one dialog screen. I'm using the OO ALV model (SALV* classes).
The user can select any number of rows from each grid. Then, when a toolbar pushbutton is pressed, I'd have to retrieve the selected rows from both grids and start some processing with these rows.
It is no problem to assign event handlers to both grids, and use the CL_SALV_TABLE->GET_SELECTIONS and CL_SALV_SELECTIONS->GET_SELECTED_ROWS methods to find out which rows were marked by the user. Trouble is, this only works when I raise an event in each grid separately, for instance via an own function that I added to the grid's toolbar. So, I can only see the selected rows of the same grid where such an event was raised.
If I try to do this in the PBO of the dialog screen (that contains the two grids), the result of CL_SALV_SELECTIONS->GET_SELECTED_ROWS will be empty, as the program does not recognize the marked entries in the grids. Also, an event for grid1 does not see the selected rows from grid2 either.
As it is right now, I can have an own button in both grid's toolbar, select the rows, click on the extra button in each grid (this will tell me what entries were selected per grid). Then, I'd have to click on a third button (the one in the dialog screen's toolbar), and process the selected rows from both grids.
How can I select the rows, then click on just one button, and process the marked entries from both grids?
Is it somehow possible to raise an event belonging to each grid programmatically, so that then the corresponding CL_SALV_SELECTIONS->GET_SELECTED_ROWS will work?
Thanks.Hello Tamas ,
If I try to do this in the PBO of the dialog screen (that contains the two grids), the result of CL_SALV_SELECTIONS->GET_SELECTED_ROWS will be empty, as the program does not recognize the marked entries in the grids. Also, an event for grid1 does not see the selected rows from grid2 either.--->
is it possible to have a check box in each grid & get the selected lines in PAI of the screen ?
regards
prabhu -
Two AlV Grids in a single screen
I want to bring two ALV GRIDS in a single report output screen.How can i achieve this through Classical coding( not OBJECT ORIENTED ). If possible please provide with codes.
thanks,
VenkatHello Venkat
I agree that using fm's this is an almost impossible task whereas using OO-based ALV lists it is just a piece of cake.
For a sample have a look at report ZUS_SDN_TWO_ALV_GRIDS in thread alv
or report ZUS_SDN_THREE_ALV_GRIDS in thread Alv
Regards
Uwe -
Two ALV Grids in a single screen are overlapping eachother
Hi,
I have created two ALV grids in a single screen. I have used seperate containers for them.
But on executing them , both the ALV grids are overlapping eachother.
Please give me a solution.Hi,
IF w_custom_container IS INITIAL.
Creating Object for the Custom Container.
CREATE OBJECT w_custom_container
EXPORTING
container_name = w_container
EXCEPTIONS
cntl_error = 1
cntl_system_error = 2
create_error = 3
lifetime_error = 4
lifetime_dynpro_dynpro_link = 5
OTHERS = 6.
CASE sy-subrc.
WHEN 1.
MESSAGE e054. "CNTL ERROR
WHEN 2.
MESSAGE e055. "CNTL SYSTEM ERROR
WHEN 3.
MESSAGE e056. "CREATE ERROR
WHEN 4.
MESSAGE e057. "LIFETIME ERROR
WHEN 5.
MESSAGE e058. "LIFETIME DYNPRO DYNPRO LINK
ENDCASE.
Creating object for the Splitter Container.
CREATE OBJECT w_split_container
EXPORTING
parent = w_custom_container
orientation = 0
sash_position = 30
with_border = 2
EXCEPTIONS
cntl_error = 1
cntl_system_error = 2
OTHERS = 3.
CASE sy-subrc.
WHEN 1.
MESSAGE e054. "CNTL_ERROR
WHEN 2.
MESSAGE e055. "CNTL_SYSTEM_ERROR
ENDCASE.
Creating Grid Control.
CREATE OBJECT w_grid1
EXPORTING
i_parent = w_split_container->top_left_container.
CREATE OBJECT w_grid2
EXPORTING
i_parent = w_split_container->bottom_right_container.
Building field catalog for ALV.
Fieldcat for the Detail Record.
PERFORM build_fieldcat USING: c_1 c_code c_output c_check
c_comcode c_olength,
c_2 c_fileno c_output c_check
c_filenum c_olength,
c_3 c_dedcod c_output c_check
c_dedcode c_olength,
c_4 c_dedfac c_output c_check
c_dedf c_olength.
FieldCatlog for the Error Records.
PERFORM build_fieldcat_error USING: c_1 c_pernr c_error c_check
c_person c_olength,
c_2 c_desc c_error c_check
c_descp c_olength.
ALV Display.
CALL METHOD w_grid1->set_table_for_first_display
EXPORTING
i_buffer_active =
i_bypassing_buffer =
i_consistency_check =
i_structure_name =
is_variant =
i_save =
i_default = 'X'
is_layout =
is_print =
it_special_groups =
it_toolbar_excluding =
it_hyperlink =
it_alv_graphics =
it_except_qinfo =
ir_salv_adapter =
CHANGING
it_outtab = t_error
it_fieldcatalog = t_fieldcat_error
it_sort =
it_filter =
EXCEPTIONS
invalid_parameter_combination = 1
program_error = 2
too_many_lines = 3
OTHERS = 4
CASE sy-subrc.
WHEN 1.
MESSAGE e076. "invalid parameter combination
WHEN 2.
MESSAGE e001. "program error
WHEN 3.
MESSAGE e078. "too many lines
ENDCASE.
CALL METHOD w_grid2->set_table_for_first_display
EXPORTING
i_buffer_active =
i_bypassing_buffer =
i_consistency_check =
i_structure_name =
is_variant =
i_save =
i_default = 'X'
is_layout =
is_print =
it_special_groups =
it_toolbar_excluding =
it_hyperlink =
it_alv_graphics =
it_except_qinfo =
ir_salv_adapter =
CHANGING
it_outtab = t_output
it_fieldcatalog = t_fieldcat
it_sort =
it_filter =
EXCEPTIONS
invalid_parameter_combination = 1
program_error = 2
too_many_lines = 3
OTHERS = 4
CASE sy-subrc.
WHEN 1.
MESSAGE e076. "invalid parameter combination
WHEN 2.
MESSAGE e001. "program error
WHEN 3.
MESSAGE e078. "too many lines
ENDCASE.
ELSE.
CALL METHOD w_grid1->refresh_table_display
EXPORTING
i_soft_refresh = 'X'.
CALL METHOD w_grid2->refresh_table_display
EXPORTING
i_soft_refresh = 'X'.
ENDIF.
Hope it Helps,
Jayant Sahu. -
Can we have two alv grid in the output
Hi
Can we have two alv grid in the output?. If yes how can we do that using oops alv. I think first need to create the container on that two subscreen. is this correct? Thanks.
Regards
Raj>
Rajitha1234 wrote:
> Hi
>
> Can we have two alv grid in the output?. If yes how can we do that using oops alv. I think first need to create the container on that two subscreen. is this correct? Thanks.
>
> Regards
> Raj
Hi Rajitha,
You can have as many as ALV output in the screen By using OOPS.
By using Container you can pass ALV output.
see the sample Program SALV_TEST_TABLE.
Regards,
Prabhudas -
Report with two ALV grids and a header
Hi experts,
I have a report with two ALV grids in the same screen, each one in a separated container. The information displays it correctly. The report has been implemented by using OO Programming.
My real trouble is in the header. It must have a logo, a title with a specific font and other information.
I'll attach a capture of my need:
[Report with two ALV grids and a header|http://picasaweb.google.com/lh/photo/AcQD49QPmm-0L_jL2iMedA?feat=directlink]
Then, I want to set up the header you can see, with logo, a font with specific features. Obviously, the header you see has taken from another report. But is the same idea.
I've tried with a third container, using the CL_GUI_CONTAINER and CL_GUI_CONTAINER classes, but it doesn't work.
Any idea? Would welcome any help you can provide.
Thanks in advance,
Jorge RojasHi, Jorge.
Should the header be a"attached" to any of the ALV? Or it should be carried alone?
If first applies, you've given the solution yourself: put the info & logo in first ALV's header and invoke it from the proper method.
You could use CL_GUI_DOCKING_CONTAINER CLASS to divide screen in several containers and then, in the upper one, I would create another one docking container to divide the screen into two: the written info could be performed with an HTML viewer class and the logo with a CL_GUI_PICTURE element.
Cheers. -
Create blank screen space between two ALV grids
I want to create some blank screen space between the two ALV grids I have on the screen. Can someone tell me how to do this?
Thanks and best regards,
SandyYou don't have link the two containers.
I guess you have a grid and tree control that you want to display. So, use a different container for each of these controls, so that they appear differently.
If you don't want space in between them, you can have one container and split that into and display the tree and grid in each of the split portions.
The advantage with this will be you can resize the tree/grids using the vertical line that separates them.
Take a look at WE02 transaction to see what I am trying to explain.
Regards,
Ravi -
Background Execution Problem-Docking Container with 2 ALV Grids in one scre
Hi Friends,
I have created 2 ALV Grids in one screen - one below another using DOCKING CONTAINER.
The objects are 'g_dock_cont' and 'g_dock_cont1'.
I am getting the foreground output as expected with 2 ALV Grids.
While executing in background (F9), I am getting only output of first ALV grid. Second ALV is not getting displayed in BACKGROUND(F9) mode.
How to solve this.
FORM create_objects.
* Materials with data
IF g_dock_cont IS INITIAL.
IF sy-batch NE 'X'.
*CREATE THE OBJECT FOR DOCKING CONTAINER
CREATE OBJECT g_dock_cont
EXPORTING
side = cl_gui_docking_container=>dock_at_top
extension = 300.
ENDIF.
*CREATE THE OBJECT FOR ALV GRID
CREATE OBJECT g_alvgrid
EXPORTING i_parent = g_dock_cont.
wa_layout-grid_title =
'Materials with Data'.
ENDIF.
IF NOT I_DETAIL[] IS INITIAL.
CALL METHOD g_alvgrid->set_table_for_first_display
EXPORTING
IS_VARIANT = WA_VARIANT_STX
IS_LAYOUT = wa_layout
CHANGING
it_outtab = I_DETAIL
IT_FIELDCATALOG = LIT_FIELDCATALOG[]
EXCEPTIONS
INVALID_PARAMETER_COMBINATION = 1
PROGRAM_ERROR = 2
TOO_MANY_LINES = 3
others = 4
IF sy-subrc <> 0.
ENDIF.
ENDIF.
*MATERIALS WITHOUT DATA
IF g_dock_cont1 IS INITIAL.
IF sy-batch NE 'X'.
*CREATE THE OBJECT FOR DOCKING CONTAINER
CREATE OBJECT g_dock_cont1
EXPORTING
side = cl_gui_docking_container=>dock_at_bottom
extension = 300.
ENDIF.
*CREATE THE OBJECT FOR ALV GRID
CREATE OBJECT g_alvgrid1
EXPORTING i_parent = g_dock_cont1.
wa_layout1-grid_title =
'Materials without Data'.
ENDIF.
IF NOT I_MARA[] IS INITIAL.
CALL METHOD g_alvgrid1->set_table_for_first_display
EXPORTING
IS_LAYOUT = wa_layout1
CHANGING
it_outtab = I_MARA
IT_FIELDCATALOG = i_fieldcat[]
EXCEPTIONS
INVALID_PARAMETER_COMBINATION = 1
PROGRAM_ERROR = 2
TOO_MANY_LINES = 3
others = 4
IF sy-subrc <> 0.
ENDIF.
ENDIF.
ENDFORM. " create_objects
Regards,
Viji.Hi,
What i was saying is that you need to code again for background mode of execution.
AT END OF SELECTION.
IF SY-BATCH EQ 'X'.
PERFORM DISPLAY1.
PERFORM DISPLAY2.
In DISPLAY1 use REUSE_ALV_LIST_DISPLAY to display data from outtab1.
In DISPLAY2 use REUSE_ALV_LIST_DISPLAY to display data from outtab2.
For example : execute this report in background mode.this will not execute in online mode.
After execution you will get two spools one for KNA1 and one for LFA1 data. Spool can be controlled via IS_PRINT structure.
report zrbackground.
data gt_lfa1 type standard table of lfa1.
data gt_kna1 type standard table of kna1.
start-of-selection.
select * from lfa1 into table gt_lfa1 up to 10 rows.
select * from kna1 into table gt_kna1 up to 20 rows.
end-of-selection.
if sy-batch eq 'X'.
perform display_lfa1.
perform display_kna1.
endif.
*& Form DISPLAY_LFA1
text
--> p1 text
<-- p2 text
form display_lfa1 .
call function 'REUSE_ALV_LIST_DISPLAY'
exporting
i_callback_program = sy-repid
i_structure_name = 'LFA1'
tables
t_outtab = gt_lfa1
exceptions
program_error = 1
others = 2.
if sy-subrc <> 0.
message id sy-msgid type sy-msgty number sy-msgno
with sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
endif.
endform. " DISPLAY_LFA1
*& Form DISPLAY_KNA1
text
--> p1 text
<-- p2 text
form display_kna1 .
call function 'REUSE_ALV_LIST_DISPLAY'
exporting
i_callback_program = sy-repid
i_structure_name = 'KNA1'
tables
t_outtab = gt_kna1
exceptions
program_error = 1
others = 2.
if sy-subrc <> 0.
message id sy-msgid type sy-msgty number sy-msgno
with sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
endif.
endform. " DISPLAY_KNA1
Please let me know if its not clear or you need more info.
Thanks,
Abhishek
Edited by: abhishek sinha on May 8, 2009 7:42 PM
Edited by: abhishek sinha on May 8, 2009 8:45 PM -
How to export two diferents DB to one unique DB
Hi people,
I doubt whether it is possible to export two different databases, each of them a central instance in different machines, one machine where the two instances together and merge these data bases on a single BD.Data from both database consolidated into a single database, apart from the two move from DB to non unicode unicode.
Thanks!!!!No.
If you want to merge systems you need to buy an SLO service, check http://service.sap.com/slo. That group has the tools to consolidate several systems on one.
Markus -
Is it possible to create two apple ID on one iTunes account?
I bought my wife an iPod Touch, how can I keep my contacts seperate from hers?
Phil, I am confused about your statement/answer:
""Is it possible to create two Apple IDs on one iTunes account?"
Yes. I have two."
Apple says:
"An Apple ID is a user name you use for everything you do with Apple. Creating an account for an Apple service, such as the iTunes Store or the App Store, creates an Apple ID. Apple ID allows you to access other Apple services. You don't have to create a new account for each service—just use your Apple ID."
Thus an Apple ID is the same as the iTunes account.
Did you mean can yu use more than one Apple ID on one iPod because yuo know the answr is yes.
Or have I go something wrong? -
Is it possible to have two apple loans under one account?
So back in June my mum took up apple finance so I could get a macbook and pay her each month (I was under 18 at the time and have no credit history) and that went through within a minute no issues..
Now I face another issue, I want the new iphone 5s but still within my current iphone 5 contract I can't get out of but that aside my question is:
Is it possible to have two apple loans under one bank account? (the iphone one being much smaller than the existing mac loan)
If not, I'll simply have to save up £700.
Thanks~Hi babowa,
The reference to two Apple loans led me to believe it was two Apple finance deals in conjunction with, for example, a Barclays Bank tie-up as we appear to have here in the UK. As you suggest, the payment is a matter between the poster and his mom, but I think that behind all this is the question of whether the poster's mom can have two separate accounts in this way. Which of course, she can. -
Hi,
Is it possible to apply two different fonts to one string, or use symbols amongst normal font? My purpose is to display an Omega symbol after some number.
".99982 Ω" or "-180 φ"
I am using version 6.0,
Thanks in advance!
Solved!
Go to Solution.It's not possible to use differnt fonts in the same text control (string, text message, text box, listbox...) or in the label for any control.
An alternative solution can be to use a font that natively includes the letters / symbols you need. Within CVI 6 native fonts you can use NISystemMetaFont which includes uppercase omega letter together with other commonly used greek letters (and uppercase / lowercase alphabet and numbers, of course ).
In charmap the font is seen as NISYSTEM: with that program you can see all characters included in the font file and select / copy each of them to paste in CVI controls if you need it.
Proud to use LW/CVI from 3.1 on.
My contributions to the Developer Zone Community
If I have helped you, why not giving me a kudos? -
Is it possible to combine two pivot report into one ?..
Is it possible to combine two pivot report into one ?..
Then trying to display a chart or table result.Thanks for the reply.
Let me explain it briefly. I am creating a Report 1 based on one fitler condition and second report is created based on second filter condition.
I have similar column (time periods) in the both report. Then measure column has to combine and show as single report.
This is my requirement. -
is it possible to have two iTunes programs on one computer to be used by two different users without songs, photos etc. being commingled?
Yes. See Here...
How to Use Multiple iDevices with One Computer
Create a New User Account for each User. Then Each user will have their own iTunes library..
Also... Have a read here...
https://discussions.apple.com/message/18409815?ac_cid=ha -
Need to display two ALV GRIDs in a single screen
Hi,
I have a question, i'm using version 4.6. I want to display 2 ALVs in a single screen or by calling.
Step 1 : The internal table (which holds the data for the ALVs has to be populated before calling ALV1 or ALV2)
Step 2 : Display In a single report
ALV1 report (Editable ,Has to be a GRID)
ALV2 report (Non Editable, Has to be a GRID)
(or)
Step 1 : The internal table (which holds the data for the ALVs has to be populated before calling ALV1 or ALV2)
Step 2 :
ALV1 report (Editable ,Has to be a GRID, with a custom button to call ALV2 hiding the ALV1 ie not visible to user)
ALV2 report (Non Editable ,Has to be a GRID, with a custom button to call ALV1 hiding the ALV2 ie not visible to user)
Please help me <b><REMOVED BY MODERATOR></b>
Message was edited by:
Alvaro Tejada GalindoHi
ABAP List Viewer
Simple ALV report
http://www.sapgenie.com/abap/controls/alvgrid.htm
http://wiki.ittoolbox.com/index.php/Code:Ultimate_ALV_table_toolbox
ALV
1. Please give me general info on ALV.
http://www.sapfans.com/forums/viewtopic.php?t=58286
http://www.sapfans.com/forums/viewtopic.php?t=76490
http://www.sapfans.com/forums/viewtopic.php?t=20591
http://www.sapfans.com/forums/viewtopic.php?t=66305 - this one discusses which way should you use - ABAP Objects calls or simple function modules.
2. How do I program double click in ALV?
http://www.sapfans.com/forums/viewtopic.php?t=11601
http://www.sapfans.com/forums/viewtopic.php?t=23010
Check the program in the following link:
http://sap-img.com/abap/display-secondary-list-using-alv-grid.htm
3. How do I add subtotals (I have problem to add them)...
http://www.sapfans.com/forums/viewtopic.php?t=20386
http://www.sapfans.com/forums/viewtopic.php?t=85191
http://www.sapfans.com/forums/viewtopic.php?t=88401
http://www.sapfans.com/forums/viewtopic.php?t=17335
http://www.sapdevelopment.co.uk/reporting/alv/alvgrid_basic.htm
4. How to add list heading like top-of-page in ABAP lists?
http://www.sapfans.com/forums/viewtopic.php?t=58775
http://www.sapfans.com/forums/viewtopic.php?t=60550
http://www.sapfans.com/forums/viewtopic.php?t=16629
5. How to print page number / total number of pages X/XX in ALV?
http://www.sapfans.com/forums/viewtopic.php?t=29597 (no direct solution)
6. ALV printing problems. The favourite is: The first page shows the number of records selected but I don't need this.
http://www.sapfans.com/forums/viewtopic.php?t=64320
http://www.sapfans.com/forums/viewtopic.php?t=44477
7. How can I set the cell color in ALV?
http://www.sapfans.com/forums/viewtopic.php?t=52107
8. How do I print a logo/graphics in ALV?
http://www.sapfans.com/forums/viewtopic.php?t=81149
http://www.sapfans.com/forums/viewtopic.php?t=35498
http://www.sapfans.com/forums/viewtopic.php?t=5013
9. How do I create and use input-enabled fields in ALV?
http://www.sapfans.com/forums/viewtopic.php?t=84933
http://www.sapfans.com/forums/viewtopic.php?t=69878
10. How can I use ALV for reports that are going to be run in background?
http://www.sapfans.com/forums/viewtopic.php?t=83243
http://www.sapfans.com/forums/viewtopic.php?t=19224
11. How can I display an icon in ALV? (Common requirement is traffic light icon).
http://www.sapfans.com/forums/viewtopic.php?t=79424
http://www.sapfans.com/forums/viewtopic.php?t=24512
12. How can I display a checkbox in ALV?
http://www.sapfans.com/forums/viewtopic.php?t=88376
http://www.sapfans.com/forums/viewtopic.php?t=40968
http://www.sapfans.com/forums/viewtopic.php?t=6919
13. Top-of-page in ALV
selection-screen and top-of-page in ALV
14. ALV Group Heading
http://www.sap-img.com/fu037.htm
How to add list heading like top-of-page in ABAP lists?
http://www.sapfans.com/forums/viewtopic.php?t=58775
http://www.sapfans.com/forums/viewtopic.php?t=60550
http://www.sapfans.com/forums/viewtopic.php?t=16629
15. ALV output to PDF conversion
It has an example code for PDF Conversion.
http://www.erpgenie.com/abap/code/abap51.htm
converting the output of alv in pdf
Go thru these programs they may help u to try on some hands on
ALV Demo program
BCALV_DEMO_HTML
BCALV_FULLSCREEN_DEMO ALV Demo: Fullscreen Mode
BCALV_FULLSCREEN_DEMO_CLASSIC ALV demo: Fullscreen mode
BCALV_GRID_DEMO Simple ALV Control Call Demo Program
BCALV_TREE_DEMO Demo for ALV tree control
BCALV_TREE_SIMPLE_DEMO
BC_ALV_DEMO_HTML_D0100
The common features of report are column alignment, sorting, filtering, subtotals, totals etc. To implement these, a lot of coding and logic is to be put. To avoid that we can use a concept called ABAP List Viewer (ALV).
This helps us to implement all the features mentioned very effectively.
Using ALV, We can have three types of reports:
1. Simple Report
2. Block Report
3. Hierarchical Sequential Report
There are some function modules which will enable to produce the above reports without much effort.
All the definitions of internal tables, structures and constants are declared in a type-pool called SLIS.
1. SIMPLE REPORT.
The important function modules are
a. Reuse_alv_list_display
b. Reuse_alv_fieldcatalog_merge
c. Reuse_alv_events_get
d. Reuse_alv_commentary_write
e. Reuse_alv_grid_display
A. REUSE_ALV_LIST_DISPLAY : This is the function module which prints the data.
The important parameters are :
I. Export :
i. I_callback_program : report id
ii. I_callback_pf_status_set : routine where a user can set his own pf status or change the functionality of the existing pf status
iii. I_callback_user_command : routine where the function codes are handled
iv. I_structure name : name of the dictionary table
v. Is_layout : structure to set the layout of the report
vi. It_fieldcat : internal table with the list of all fields and their attributes which are to be printed (this table can be populated automatically by the function module REUSE_ALV_FIELDCATALOG_MERGE
vii. It_events : internal table with a list of all possible events of ALV and their corresponding form names.
II. Tables :
i. t_outtab : internal table with the data to be output
B. REUSE_ALV_FIELDCATALOG_MERGE : This function module is used to populate a fieldcatalog which is essential to display the data in ALV. If the output data is from a single dictionary table and all the columns are selected, then we need not exclusively create the field catalog. Its enough to mention the table name as a parameter(I_structure name) in the REUSE_ALV_LIST_DISPLAY. But in other cases we need to create it.
The Important Parameters are :
I. Export :
i. I_program_name : report id
ii. I_internal_tabname : the internal output table
iii. I_inclname : include or the report name where all the dynamic forms are handled.
II Changing
ct_fieldcat : an internal table with the type SLIS_T_FIELDCAT_ALV which is
declared in the type pool SLIS.
C. REUSE_ALV_EVENTS_GET : Returns table of possible events for a list type
Parameters :
I. Import :
Et_Events : The event table is returned with all possible CALLBACK events
for the specified list type (column 'NAME'). For events to be processed by Callback, their 'FORM' field must be filled. If the field is initialized, the event is ignored. The entry can be read from the event table, the field 'FORM' filled and the entry modified using constants from the type pool SALV.
II. Export :
I_List_type :
0 = simple list REUSE_ALV_LIST_DISPLAY
1 = hierarchcal-sequential list REUSE_ALV_HIERSEQ_LIST_DISPLAY
2 = simple block list REUSE_ALV_BLOCK_LIST_APPEND
3 = hierarchical-sequential block list
REUSE_ALV_BLOCK_LIST_HS_APPEND
D. REUSE_ALV_COMMENTARY_WRITE : This is used in the Top-of-page event to print the headings and other comments for the list.
Parameters :
I. it_list_commentary : internal table with the headings of the type slis_t_listheader.
This internal table has three fields :
Typ : H header, S selection , A - action
Key : only when typ is S.
Info : the text to be printed
E. REUSE_ALV_GRID_DISPLAY : A new function in 4.6 version, to display the results in grid rather than as a preview.
Parameters : same as reuse_alv_list_display
This is an example for simple list.
2. BLOCK REPORT
This is used to have multiple lists continuously.
The important functions used in this report are:
A. REUSE_ALV_BLOCK_LIST_INIT
B. REUSE_ALV_BLOCK_LIST_APPEND
C. REUSE_ALV_BLOCK_LIST_HS_APPEND
D. REUSE_ALV_BLOCK_LIST_DISPLAY
A. REUSE_ALV_BLOCK_LIST_INIT
Parameters:
I. I_CALLBACK_PROGRAM
II. I_CALLBACK_PF_STATUS_SET
III. I_CALLBACK_USER_COMMAND
This function module is used to set the default gui status etc.
B. REUSE_ALV_BLOCK_LIST_APPEND
Parameters :
Export :
I. is_layout : layout settings for block
II. it_fieldcat : field catalog
III. i_tabname : internal table name with output data
IV. it_events : internal table with all possible events
Tables :
i. t_outtab : internal table with output data.
This function module adds the data to the block.
Repeat this function for all the different blocks to be displayed one after the other.
C. REUSE_ALV_BLOCK_LIST_HS_APPEND
This function module is used for hierarchical sequential blocks.
D. REUSE_ALV_BLOCK_LIST_DISPLAY
Parameters : All the parameters are optional.
This function module display the list with data appended by the above function.
Here the functions REUSE_ALV_FIELDCATALOG_MERGE, REUSE_ALV_EVENTS_GET, REUSE_ALV_COMMENTARY_WRITE can be used.
3. Hierarchical reports :
Hierarchical sequential list output.
The function module is
A. REUSE_ALV_HIERSEQ_LIST_DISPLAY
Parameters:
I. Export:
i. I_CALLBACK_PROGRAM
ii. I_CALLBACK_PF_STATUS_SET
iii. I_CALLBACK_USER_COMMAND
iv. IS_LAYOUT
v. IT_FIELDCAT
vi. IT_EVENTS
vii. i_tabname_header : Name of the internal table in the program containing the
output data of the highest hierarchy level.
viii. i_tabname_item : Name of the internal table in the program containing the
output data of the lowest hierarchy level.
ix. is_keyinfo : This structure contains the header and item table field
names which link the two tables (shared key).
II. Tables
i. t_outtab_header : Header table with data to be output
ii. t_outtab_item : Name of the internal table in the program containing the
output data of the lowest hierarchy level.
slis_t_fieldcat_alv : This internal table contains the field attributes. This internal table can be populated automatically by using REUSE_ALV_FIELDCATALOG_MERGE.
Important Attributes :
A. col_pos : position of the column
B. fieldname : internal fieldname
C. tabname : internal table name
D. ref_fieldname : fieldname (dictionary)
E. ref_tabname : table (dictionary)
F. key(1) : column with key-color
G. icon(1) : icon
H. symbol(1) : symbol
I. checkbox(1) : checkbox
J. just(1) : (R)ight (L)eft (C)ent.
K. do_sum(1) : sum up
L. no_out(1) : (O)blig.(X)no out
M. outputlen : output length
N. seltext_l : long key word
O. seltext_m : middle key word
P. seltext_s : short key word
Q. reptext_ddic : heading (ddic)
R. ddictxt(1) : (S)hort (M)iddle (L)ong
S. datatype : datatype
T. hotspot(1) : hotspot
Regards
Anji
Maybe you are looking for
-
Generating a Vendor UUID and Product ID
I understand the concept of UUID and a product ID, but I don't know in practice how to go about getting one. I'm working on making an appliance for my company, and let me preface this by saying I'm not a developer, and I'm wondering if a vendor UUID
-
Could not load applet in a browser using jre 1.6.0_06
Hi, I am facing problem with loading applets when the browser uses jre 1.6.0_06. Not able to understand what actually the problem is, I tried to check with a small applet that would simply print Hello World on the java console. Even this applet also
-
How do I stream my Mac to my apple TV?
I'm wanting to watch somthing from the internet to my apple TV without conecting it to my mac.
-
HP p6710f Lost DVI Video Output
Hello, I am using a P6710F HP Desktop with dual monitors. This video card is built onto the motherboard. One is VGA and the other is DVI. Just today I have lost the signal on the DVI, right after a reboot. Is there any tools to test the video ports?
-
Alert Framework Creation...
Hi All, In our current production environment all the alerts of different functional tracks are coming to the admins assigned under fixed reciepients(under alrtcatdef). Now we are planning to segregate these alerts based upon different functional tra