2007 Mar 06 2:38 PM
Hi Experts,
i have one requirement. i need to Develop Alvgrid in one Screen.in the Same Screen another Grid.in First i need to Display Summary information.if we Double Click on First Grid of line Detail output of paricular contract.How to Acheive using classes.
plz send me the material Regarding this.and give me Some examples.How to approach.
Thanks,
Venkat.
2007 Mar 07 5:34 AM
Hello,
<b>Check this link:</b>
http://www.geocities.com/mpioud/Z_DEMO_2_ALV_LIST.html
This program is an example with 2 ALV Grid lists.The Sales Orders are displayed in the first list.When a line is selected, the items of the order are displayed in the second list.
Regards,
Beejal
**reward if this helps
2007 Mar 06 4:03 PM
Hi,
Here is a code for a single grid.
In the screen layout,make a custom container (Icon with C ) and name it in Capital letters as CONTAINER.The code below in bold letters is what exactly you want.I ve given a small example on how to use ALV:
REPORT SAMPLE.
DATA: alv type ref to cl_gui_alv_GRID,
cont type ref to cl_gui_custom_container,
itab_spfli type table of spfli.
START-OF-SELECTION.
select * from spfli into table itab_spfli.
call screen 100.
END-OF-SELECTION.
&----
*& Module STATUS_0100 OUTPUT
&----
text
----
MODULE STATUS_0100 OUTPUT.
seT PF-STATUS 'GUI'.
SET TITLEBAR 'xxx'.
if cont is initial.
CREATE OBJECT cont
EXPORTING
CONTAINER_NAME = 'CONTAINER'.
CREATE OBJECT ALV
EXPORTING
I_PARENT = CONT.
CALL METHOD ALV->SET_TABLE_FOR_FIRST_DISPLAY
EXPORTING
I_STRUCTURE_NAME = 'SPFLI'
CHANGING
IT_OUTTAB = itab_spfli
Now for your requirement,you can create two custom containers in the screen layout and two different alv grid instances.ie:
DATA: alv1 type ref to cl_gui_alv_GRID,
cont1 type ref to cl_gui_custom_container
alv2 type ref to cl_gui_alv_GRID,
cont2 type ref to cl_gui_custom_container.
To select data from first grid,you can use events on double_click and fetch information and then display it in the second grid.
<b>SOME MATERIAL REGARDING ALV:</b>
www.abap4.it/download/ALV.pdf <b>(very useful)</b>
http://www.sapdevelopment.co.uk/reporting/alvhome.htm
<b>-->download the PDF from following link.</b>
http://help.sap.com/printdocu/core/Print46c/en/data/pdf/BCSRVALV/BCSRVALV.pdf
http://www.sapdevelopment.co.uk/reporting/alv/alvgrid_color.htm
<b>SAMPLE PROGRAMS IN ALV:</b>http://www.geocities.com/victorav15/sapr3/abap_ood.html#d_grid
<b>DEMO PROGRAMS IN ALV:</b>BCALV*
Regards,
Beejal
**Reward if this helps
2007 Mar 07 5:34 AM
Hello,
<b>Check this link:</b>
http://www.geocities.com/mpioud/Z_DEMO_2_ALV_LIST.html
This program is an example with 2 ALV Grid lists.The Sales Orders are displayed in the first list.When a line is selected, the items of the order are displayed in the second list.
Regards,
Beejal
**reward if this helps
2007 Mar 07 6:06 AM
Hi,
Thanks For u r Reply.
But My Requirement is in the Same Screeen i need to Display two alv grids,
in top of the Screen Basic information. and below the Detail list.
How to approch this requirement.
Thanks,
Venkat.
2007 Mar 07 9:04 AM
Hi,
you have to use SPLITTER CONTROL for this,
class CL_GUI_SPLITTER_CONTAINER
chack the program RSDEMO_SPLITTER_CONTROL
Regards,
hope it helps
2007 Mar 09 9:05 AM
hi,
see the demo program BCALV_GRID_03.
this will help u.
regards,
Naresh.