Posted: Fri Dec 28, 2012 12:55 pm Post subject: внедрение BADI в программу
Нужна помощь с прогой.
Написал такой код:
Code:
DATA : et_ekko TYPE TABLE OF ekko,
et_ekpo TYPE TABLE OF ekpo .
DATA :
w_handle TYPE REF TO ZCL_TEST01, " ZCL_TEST01 - BADi-определение
ob_custom TYPE REF TO cl_gui_custom_container ,
ob_split1 TYPE REF TO cl_gui_easy_splitter_container ,
ob_split2 TYPE REF TO cl_gui_easy_splitter_container ,
ob_grid1 TYPE REF TO cl_gui_alv_grid ,
ob_grid2 TYPE REF TO cl_gui_alv_grid .
DATA :
OK_CODE LIKE sy-ucomm,
SAVE_OK LIKE sy-ucomm.
PARAMETER iv_ebeln type ekko-ebeln.
START-OF-SELECTION.
* GET BADI - for getting objects..................
GET BADI w_handle.
* CALL BADI - for calling interface methods.
CALL BADI w_handle->select_data
EXPORTING
iv_ebeln = iv_ebeln
IMPORTING
et_ekpo = et_ekpo
et_ekko = et_ekko
MODULE status_0100 OUTPUT.
SET TITLEBAR 'DYNPRO' .
SET PF-STATUS 'DYNPR'.
* This will create a container
CREATE OBJECT ob_custom
EXPORTING
container_name = 'CONTAINER' .
* This spit the container OB_CUSTOM into two
CREATE OBJECT ob_split1
EXPORTING
parent = ob_custom
orientation = cl_gui_easy_splitter_container=>orientation_vertical .
Программа, основанная на BADI для ввода номера документа и вывода результата в ALV сплит контейнеры.
нужно сделать так, что бы выбор данных должен осуществляться в программе и далее данные должны передаваться в бади для редактирования.
И осуществить внедрение бади с реализацией редактирования в методе.
Code:
method zcl_test_01_interface~select_data.
select *
from ekko
into table et_ekko
where ebeln = iv_ebeln.
select *
from ekpo
into table et_ekpo
where ebeln = iv_ebeln.
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum You cannot attach files in this forum You can download files in this forum
All product names are trademarks of their respective companies. SAPNET.RU websites are in no way affiliated with SAP AG. SAP, SAP R/3, R/3 software, mySAP, ABAP, BAPI, xApps, SAP NetWeaver and any other are registered trademarks of SAP AG. Every effort is made to ensure content integrity. Use information on this site at your own risk.