cancel
Showing results for 
Search instead for 
Did you mean: 

Access value in view under overview page

Former Member
0 Kudos

Hi experts

i need to access data in the overview page which is there in a view under this page. the data is there in the context node of the view.how can i access this context node?

Rahul

Accepted Solutions (1)

Accepted Solutions (1)

0 Kudos

Hi Rahul,

You can access the views under the overview page. The sample code to achieve the same is as given below.

DATA:
    lr_window TYPE REF TO cl_bsp_wd_window,
    lr_viewset      TYPE REF TO cl_bsp_wd_view_controller,
    lr_slsoitemview         TYPE REF TO CL_SLSOItemview_IMPL.
 
lr_window ?= me->get_subcontroller_by_viewname( 'SLSOMainWindow' ).
  if  lr_window IS BOUND.
    lr_viewset ?= lr_window->get_subcontroller_by_viewname( 'SLSOHeaderOV' ).
    if lr_viewset IS BOUND.
      lr_slsoitemview  ?= lr_viewset->get_subcontroller_by_viewname( 'SLSOItemview' ).
      if lr_slsoitemview  IS BOUND.
        TRY.
            "access the context node of the view here"
          CATCH cx_sy_dyn_call_error.
            RETURN.
        ENDTRY.
      endif.
    endif.
  endif.

The other way you can achieve this is by binding the context node to the component or custom controller and then bind it to your overview page.

Regards,

Leon

Answers (0)