Sales data flow based on User Input using FPM Framework (Web Dynpro for ABAP)

...Previous

Step 4: Map the context of controller to the View Header and design the layout as follows

Step 5: Embed the Select_options Standard component in the Used components

Go to Component Controller and give global attribute M_HANDLER with ref to IF_WD_SELECT_OPTIONS

Copy the below code in the WDDOINIT( ) method of component controller

method WDDOINIT .
  
DATA lo_cmp_usage TYPE REF TO if_wd_component_usage.

  lo_cmp_usage =   wd_this->wd_cpuse_select_options( ).
  
IF lo_cmp_usage->has_active_component( ) IS INITIAL.
    lo_cmp_usage->create_component( ).
  
ENDIF.

DATA lo_interfacecontroller TYPE REF TO iwci_wdr_select_options .
lo_interfacecontroller =   wd_this->wd_cpifc_select_options( ).

  wd_this->m_handler = lo_interfacecontroller->init_selection_screen(
  ).
data:
  lt_range 
TYPE REF TO data,
  lt_range1 
TYPE REF TO data.
CALL METHOD wd_this->m_handler->create_range_table
  
EXPORTING
    i_typename     = 
'VKORG'
*    i_length       =
*    i_decimals     =
  receiving
    rt_range_table = lt_range
    .
CALL METHOD wd_this->m_handler->create_range_table
  
EXPORTING
    i_typename     = 
'VTWEG'
  receiving
    rt_range_table = lt_range1
    .

CALL METHOD wd_this->m_handler->add_selection_field
  
EXPORTING
    i_id                         = 
'VKORG'
*    i_within_block               = MC_ID_MAIN_BLOCK
*    i_description                =
*    i_is_auto_description        = ABAP_TRUE
    it_result                    = lt_range
    .
CALL METHOD wd_this->m_handler->add_selection_field
  
EXPORTING
    i_id                         = 
'VTWEG'
*    i_within_block               = MC_ID_MAIN_BLOCK
*    i_description                =
*    i_is_auto_description        = ABAP_TRUE
    it_result                    = lt_range1.


endmethod.

Go to window and embed the Standard WIND_SELECTION_SCREEN into VIEW CONTAINER of HEADER view

Step 6: Map the context of controller to the View  LINE_ITEM and design the layout as follows

Step 7: Map the context of controller to the View CONDITION and design the layout as follows

Click here to continue...

 

Please send us your feedback/suggestions at webmaster@SAPTechnical.COM 

HomeContribute About Us Privacy Terms Of Use • Disclaimer • SafeCompanies: Advertise on SAPTechnical.COM | Post JobContact Us  

Graphic Design by Round the Bend Wizards

footer image footer image