‎2007 Jun 25 10:04 AM
hi,
I WANT SOME OOPS ALV MATERIAL AN D EXAPMLE FOR EACH TYPE OF ALV .PLEASE SEND THE MATERIAL.
THANK YOU
ASHOK KUMAR
‎2007 Jun 25 10:06 AM
Hi,
some links.
http://help.sap.com/saphelp_nw2004s/helpdata/en/5e/88d440e14f8431e10000000a1550b0/frameset.htm
download the PDF from following link.
http://help.sap.com/printdocu/core/Print46c/en/data/pdf/BCSRVALV/BCSRVALV.pdf
The ALV object Grid methods allow the same functionality as ALV grid report function modules but are displayed within
a screen (dialog program). SAP has provided a suit of programs which demonstrate how to For examples see standard SAP
programs as detailed below:
BCALV_EDIT_01 This report illustrates the simplest case of using an editable/noneditable ALV Grid Control.
BCALV_EDIT_02 This report illustrates how to set chosen cells of an ALV Grid Control editable.
BCALV_EDIT_03 In this example the user may change values of fields SEATSOCC (occupied seats) and/or PLANETYPE.
The report checks the input value(s) semantically and provides protocol messages in case of error
BCALV_EDIT_04 This report illustrates how to add and remove lines to a table using the ALV Grid Control and how to
implement the saving of the new data.
BCALV_EDIT_05 This example shows how to use checkboxes within an ALV Grid Control. You learn:
(1) how to define a column for editable checkboxes for an attribute of your list
(2) how to evaluate the checked checkboxes
(3) how to switch between editable and non-editable checkboxes
BCALV_EDIT_06 This example shows how to define a dropdown listbox for all cells of one column in an editable ALV
Grid Control.
BCALV_EDIT_07 This example shows how to define dropdown listboxes for particular cells of your output table.
BCALV_EDIT_08 This report implements an ALV Grid Control with an application specific F4 help. The following aspects
are dealt with:
(1) how to replace the standard f4 help
(2) how to pass the selected value to the ALV Grid Control
(3) how to build an f4 help, whose value range depend on a value of another cell.
You can refer these documents also.
http://esnips.com/doc/b708766f-a934-42a1-8064-c4de75b48fc4/Sample-Program-of-alv-using-oops.ppt
http://esnips.com/doc/a2e42503-cf0f-4418-94ee-580f5900a81f/alv-with-oop.doc
http://esnips.com/doc/2d953590-e8c5-490c-a607-d1ab7cf517d7/ALV.pdf
Sample programs:
http://www.geocities.com/victorav15/sapr3/abap_ood.html#d_grid
http://www.sapdevelopment.co.uk/reporting/alv/alvgrid_color.htm
http://www.sapdevelopment.co.uk/reporting/alvhome.htm
-->download the PDF from following link.
http://help.sap.com/printdocu/core/Print46c/en/data/pdf/BCSRVALV/BCSRVALV.pdf
Some more:
http://www.sap-hefte.de/download/dateien/1025/087_leseprobe.pdf
http://www.alvgmbh.de/dwnload/gonio_t.pdfhttp://
Regards,
Priyanka.
‎2007 Jun 25 10:07 AM
‎2007 Jun 25 10:07 AM
HI Ashok.
Please refer this code.
Sales Order Flow Tree Report
report z_sales_tree_rpt .
*******************************************************************
Create a tree report of sales orders to deliveries to invoices *
*******************************************************************
include z_sales_tree_rpt_top.
include z_sales_tree_class_def.
selection-screen begin of block a0 with frame title text-001.
*selection-screen comment 5(60) text-c00 modif id sc1.
selection-screen begin of block b5 with frame title text-s05.
select-options:
s_erdat for vbak-erdat,
s_ernam for vbak-ernam.
parameters: s_vbtyp like vbfa-vbtyp_n default 'C'.
selection-screen end of block b5.
selection-screen end of block a0.
----
Initialization
----
*at selection-screen output.
perform update_sel_screen_attributes.
----
Start of Selection
----
start-of-selection.
refresh: itab_data, itab_selection.
perform update_selection_table tables itab_selection.
perform create_input_table tables itab_data
itab_selection.
if not itab_data is initial.
create the application object
this object is needed to handle the ABAP Objects Events of Controls
create object g_application.
call screen 2000.
else.
message i043(z1).
endif.
end-of-selection.
----
Includes
----
include z_sales_tree_forms.
include z_sales_tree_pbo.
include z_sale_tree_pai.
----
INCLUDE Z_SALES_TREE_CLASS_DEF *
----
class lcl_application definition.
public section.
methods:
handle_node_double_click
for event node_double_click
of cl_gui_list_tree
importing node_key,
handle_expand_no_children
for event expand_no_children
of cl_gui_list_tree
importing node_key,
handle_item_double_click
for event item_double_click
of cl_gui_list_tree
importing node_key item_name,
handle_button_click
for event button_click
of cl_gui_list_tree
importing node_key item_name,
handle_link_click
for event link_click
of cl_gui_list_tree
importing node_key item_name,
handle_checkbox_change
for event checkbox_change
of cl_gui_list_tree
importing node_key item_name checked.
endclass.
----
CLASS lcl_application IMPLEMENTATION
----
........ *
----
class lcl_application implementation.
method handle_node_double_click.
" this method handles the node double click event of the tree
" control instance
" show the key of the double clicked node in a dynpro field
read table itab_data with key node_key = node_key into wa_data.
if sy-subrc = 0.
select single rfmng rfwrt matnr
into (vbfa-rfmng, vbfa-rfwrt, vbfa-matnr)
from vbfa
where vbelv = wa_data-vbeln
and posnv = wa_data-posnn.
endif.
endmethod.
method handle_item_double_click.
" this method handles the item double click event of the tree
" control instance. You have variables node_key and item_name
" show the key of the node and the name of the item
" of the double clicked item in a dynpro field
read table itab_data with key node_key = node_key into wa_data.
if sy-subrc = 0.
select single rfmng rfwrt matnr
into (vbfa-rfmng, vbfa-rfwrt, vbfa-matnr)
from vbfa
where vbelv = wa_data-vbeln
and posnv = wa_data-posnn.
endif.
endmethod.
method handle_link_click.
" this method handles the link click event of the tree
" control instance
" show the key of the node and the name of the item
" of the clicked link in a dynpro field
g_event = 'LINK_CLICK'.
g_node_key = node_key.
g_item_name = item_name.
endmethod.
method handle_button_click.
" this method handles the button click event of the tree
" control instance
" show the key of the node and the name of the item
" of the clicked button in a dynpro field
g_event = 'BUTTON_CLICK'.
g_node_key = node_key.
g_item_name = item_name.
endmethod.
method handle_checkbox_change.
" this method handles the checkbox_change event of the tree
" control instance
" show the key of the node and the name of the item
" of the clicked checkbox in a dynpro field
g_event = 'CHECKBOX_CHANGE'.
g_node_key = node_key.
g_item_name = item_name.
endmethod.
method handle_expand_no_children.
data: node_table type treev_ntab,
node type treev_node,
item_table type item_table_type,
item type mtreeitm.
show the key of the expanded node in a dynpro field
g_event = 'EXPAND_NO_CHILDREN'.
g_node_key = node_key.
if node_key = 'Child2'. "#EC NOTEXT
add the children for node with key 'Child2'
Node with key 'New3'
clear node.
node-node_key = 'New3'. "#EC NOTEXT
node-relatkey = 'Child2'.
node-relatship = cl_gui_list_tree=>relat_last_child.
append node to node_table.
Node with key 'New4'
clear node.
node-node_key = 'New4'. "#EC NOTEXT
node-relatkey = 'Child2'.
node-relatship = cl_gui_list_tree=>relat_last_child.
append node to node_table.
Items of node with key 'New3'
clear item.
item-node_key = 'New3'.
item-item_name = '1'.
item-class = cl_gui_list_tree=>item_class_text.
item-length = 11.
item-usebgcolor = 'X'. "
item-text = 'SAPTROX1'.
append item to item_table.
clear item.
item-node_key = 'New3'.
item-item_name = '2'.
item-class = cl_gui_list_tree=>item_class_text.
item-alignment = cl_gui_list_tree=>align_auto.
item-font = cl_gui_list_tree=>item_font_prop.
item-text = 'Comment to SAPTROX1'. "#EC NOTEXT
append item to item_table.
Items of node with key 'New4'
clear item.
item-node_key = 'New4'.
item-item_name = '1'.
item-class = cl_gui_list_tree=>item_class_text.
item-length = 11.
item-usebgcolor = 'X'. "
item-text = 'SAPTRIXTROX'.
append item to item_table.
clear item.
item-node_key = 'New4'.
item-item_name = '2'.
item-class = cl_gui_list_tree=>item_class_text.
item-alignment = cl_gui_list_tree=>align_auto.
item-font = cl_gui_list_tree=>item_font_prop.
item-text = 'Comment to SAPTRIXTROX'. "#EC NOTEXT
append item to item_table.
endif.
call method g_tree->add_nodes_and_items
exporting
node_table = node_table
item_table = item_table
item_table_structure_name = 'MTREEITM'
exceptions
failed = 1
cntl_system_error = 3
error_in_tables = 4
dp_error = 5
table_structure_name_not_found = 6.
if sy-subrc <> 0.
message a000(tree_control_msg).
endif.
endmethod.
endclass.
Reward all helpfull answers.
Regards.
jay
‎2007 Jun 25 10:08 AM
Hi,
http://help.sap.com/printdocu/core/Print46c/en/data/pdf/BCSRVALV/BCSRVALV.pdf
The ALV object Grid methods allow the same functionality as ALV grid report function modules but are displayed within
a screen (dialog program). SAP has provided a suit of programs which demonstrate how to For examples see standard SAP
programs as detailed below:
BCALV_EDIT_01 This report illustrates the simplest case of using an editable/noneditable ALV Grid Control.
BCALV_EDIT_02 This report illustrates how to set chosen cells of an ALV Grid Control editable.
BCALV_EDIT_03 In this example the user may change values of fields SEATSOCC (occupied seats) and/or PLANETYPE.
The report checks the input value(s) semantically and provides protocol messages in case of error
BCALV_EDIT_04 This report illustrates how to add and remove lines to a table using the ALV Grid Control and how to
implement the saving of the new data.
BCALV_EDIT_05 This example shows how to use checkboxes within an ALV Grid Control. You learn:
(1) how to define a column for editable checkboxes for an attribute of your list
(2) how to evaluate the checked checkboxes
(3) how to switch between editable and non-editable checkboxes
BCALV_EDIT_06 This example shows how to define a dropdown listbox for all cells of one column in an editable ALV
Grid Control.
BCALV_EDIT_07 This example shows how to define dropdown listboxes for particular cells of your output table.
BCALV_EDIT_08 This report implements an ALV Grid Control with an application specific F4 help. The following aspects
are dealt with:
(1) how to replace the standard f4 help
(2) how to pass the selected value to the ALV Grid Control
(3) how to build an f4 help, whose value range depend on a value of another cell.
You can refer these documents also.
http://esnips.com/doc/b708766f-a934-42a1-8064-c4de75b48fc4/Sample-Program-of-alv-using-oops.ppt
http://esnips.com/doc/a2e42503-cf0f-4418-94ee-580f5900a81f/alv-with-oop.doc
http://esnips.com/doc/2d953590-e8c5-490c-a607-d1ab7cf517d7/ALV.pdf
Sample programs:
http://www.geocities.com/victorav15/sapr3/abap_ood.html#d_grid
http://www.sapdevelopment.co.uk/reporting/alv/alvgrid_color.htm
http://www.sapdevelopment.co.uk/reporting/alvhome.htm
regards,
Omkar.
‎2007 Jun 25 10:08 AM
‎2007 Jun 25 10:10 AM
hi,
have a look at the following documentation of Rich Heilman:
regards,
Navneeth K.
‎2007 Jun 25 10:10 AM
Hello Ashok
I have posted several simplified sample report dealing with various aspects of ALV grid programming. Simply search the <i>ABAP Objects</i> forum for <b>ZUS_SDN</b>.
Regards
Uwe