cancel
Showing results for 
Search instead for 
Did you mean: 

Problem with DO_Dynamic_Navigation

Former Member
0 Kudos

Hi friends,

I need to call the methods of another component and embed in my current component view container based on the embedding position.I called the method DO_DYNAMIC_NAVIGATION. when this method got executed it goes to the target component i.e where the required view exits,but it is unable to call the method.

it returns an error saying 'View V_OEL_STATS does not exist within the component /EMN/IHIS_QUANTITATIVE_CN.

where EMN/IHIS_QUANTITATIVE_CN is calling component,but the view is in EMN/IHIS_QUANTITATIVE.

I have put a break point in EMN/IHIS_QUANTITATIVE but it is unable to call the method V_OEL_STATS .

please help me in solving the below issue.

below is the sample code i have written.

DATA : node TYPE REF TO if_wd_context_node,

dl_api_main TYPE REF TO if_wd_view_controller,

l_nav_services TYPE REF TO if_wd_navigation_services,

LV_TARGET_COMPONENT TYPE STRING,

LV_TARGET_VIEW TYPE STRING,

LV_TARGET_PLUG TYPE STRING.

DATA lo_cmp_usage TYPE REF TO if_wd_component_usage.

lo_cmp_usage = wd_this->wd_cpuse_cu_quantitative( ).

IF lo_cmp_usage->has_active_component( ) IS INITIAL.

lo_cmp_usage->create_component( ).

ENDIF.

node = wd_context->get_child_node( 'ND_VIEWS_SWITCH' ).

node->set_lead_selection_index( index ).

CASE index.

WHEN '1'."assessment groups and agents.

LV_TARGET_COMPONENT = '/EMN/IHIS_QUANTITATIVE'.

LV_TARGET_VIEW = 'V_ASSESS_GROUP_AGENT'.

LV_TARGET_PLUG = 'IP_AGENTS'.

WHEN '2'."samples

LV_TARGET_COMPONENT = '/EMN/IHIS_QUANTITATIVE'.

LV_TARGET_VIEW = 'V_SAMPLE_SHEET'.

LV_TARGET_PLUG = 'IP_SAMPLES'.

WHEN '3'."sample results

LV_TARGET_COMPONENT = '/EMN/IHIS_QUANTITATIVE'.

LV_TARGET_VIEW = 'V_SAMPLE_RESULTS_SET'.

LV_TARGET_PLUG = 'IP_RESULTS'.

WHEN '4'."sample sets

LV_TARGET_COMPONENT = '/EMN/IHIS_QUANTITATIVE'.

LV_TARGET_VIEW = 'V_SAMPLE_RESULTS_SET'.

LV_TARGET_PLUG = 'IP_SETS'.

WHEN '5'."oel

LV_TARGET_COMPONENT = '/EMN/IHIS_QUANTITATIVE'.

LV_TARGET_VIEW = 'V_OEL_STATS'.

LV_TARGET_PLUG = 'IP_OEL'.

ENDCASE.

dl_api_main = wd_this->wd_get_api( ).

l_nav_services ?= dl_api_main.

l_nav_services->do_dynamic_navigation(

source_window_name = 'W_QUANTITATIVE_CN'

source_vusage_name = 'V_MAIN_USAGE_0'

source_plug_name = 'OP_QUAN'

target_component_name = LV_TARGET_COMPONENT

target_view_name = LV_TARGET_VIEW

target_plug_name = LV_TARGET_PLUG

target_embedding_position = 'V_MAIN/VCU_GENERIC' ).

Regards,

Xavier.P

Edited by: Xavier on Jan 13, 2011 6:31 PM

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

>

> DATA lo_cmp_usage TYPE REF TO if_wd_component_usage.

>

> lo_cmp_usage = wd_this->wd_cpuse_cu_quantitative( ).

> IF lo_cmp_usage->has_active_component( ) IS INITIAL.

> lo_cmp_usage->create_component( ).

> ENDIF.

>

> WHEN '5'."oel

> LV_TARGET_COMPONENT = '/EMN/IHIS_QUANTITATIVE'.

> LV_TARGET_VIEW = 'V_OEL_STATS'.

> LV_TARGET_PLUG = 'IP_OEL'.

> ENDCASE.

> dl_api_main = wd_this->wd_get_api( ).

> l_nav_services ?= dl_api_main.

> l_nav_services->do_dynamic_navigation(

> source_window_name = 'W_QUANTITATIVE_CN'

> source_vusage_name = 'V_MAIN_USAGE_0'

> source_plug_name = 'OP_QUAN'

> target_component_name = LV_TARGET_COMPONENT

> target_view_name = LV_TARGET_VIEW

> target_plug_name = LV_TARGET_PLUG

> target_embedding_position = 'V_MAIN/VCU_GENERIC' ).

>

> Regards,

> Xavier.P

>

> Edited by: Xavier on Jan 13, 2011 6:31 PM

Hi,

your code seems to me okay. I cannot validate the usage cu_quantitative to /EMN/IHIS_QUANTITATIVE.

can you check that as well. is the source_vusage_name also correct ?

have a look into this discussion [|]

Target_view_name should be the interfaceView name and not the actual view name itself.

Edited by: Baskaran Senthivel on Jan 13, 2011 10:56 PM

Former Member
0 Kudos

Hi baskar,

Thanks for the reply,I have refered the thread which you have suggested.

for target_view_name i have passed the interface view name.( i am assuming that for each window a interface view is created),but in this window i have 4 to 5 views embedded.so it is calling all the views which are embedded in that view.

is it mandatory that each view has to embedded in a window so that it calls only the particular view when we pass the interface view name to method DO_DYNAMIC_NAVIGATION?

if that is the case I need to create Windows and assign each view to each window.

Regards,

Xavier.P

Former Member
0 Kudos

>

> Hi baskar,

> is it mandatory that each view has to embedded in a window so that it calls only the particular view when we pass the interface view name to method DO_DYNAMIC_NAVIGATION?

>

> if that is the case I need to create Windows and assign each view to each window.

>

> Regards,

> Xavier.P

Hi,

No that is not mandatory. You have interface view and you have interface plugs which connects the respective view.

So in your case i would have expected W_OEL_STATS as your window name and IP_OEL is the interface plug in the window which connects to the window.

or target_view_name i have passed the interface view name.( i am assuming that for each window a interface view is created),but in this window i have 4 to 5 views embedded

so please tell me what is your interfaceview name ? I see different names in your post. Make sure the plugs you fire are interface plugs .

Former Member
0 Kudos

hI BASKAR,

w_oel_stats is the interface view it is having 4 views. in this window ,i have created a plug called IP_OEL.I need to call a particular view V_OEL_STATS. How can I call that particular view.

WHEN '4'."oel

lv_target_component = '/EMN/IHIS_QUANTITATIVE'.

lv_target_view = 'W_IHIS_QUANTITATIVE'."'W_OEL_STATS'."'V_OEL_STATS'.

lv_target_plug = 'OP_OEL'.

ENDCASE.

dl_api_main = wd_this->wd_get_api( ).

l_nav_services ?= dl_api_main.

l_nav_services->do_dynamic_navigation(

source_window_name = 'W_QUANTITATIVE_CN'

source_vusage_name = 'V_MAIN_USAGE_0'

source_plug_name = lv_target_plug

target_component_name = lv_target_component

target_view_name = lv_target_view

target_plug_name = 'IP_OEL' IP_OEL is the plug created in interface view

target_embedding_position = 'V_MAIN/VCU_GENERIC' ).

Regards,

Xavier.P

Former Member
0 Kudos

Hi,

>

> w_oel_stats is the interface view it is having 4 views. in this window ,i have created a plug called IP_OEL.I need to call a particular view V_OEL_STATS. How can I call that particular view.

in the window you need to connect the outbound plug IP_OEL to view V_OEL_STATS in bound plug.

> lv_target_view = 'W_IHIS_QUANTITATIVE'."'W_OEL_STATS'."'V_OEL_STATS'.

i do not understand this !! do you want to go to the nested interface view then? if not then change your statement

lv_target_view = 'W_OEL_STATS'

Former Member
0 Kudos

Thank you baskar.

Regards,

Xavier.P

Answers (0)