on 10-15-2008 12:39 PM
Hi Experts,
How can I create two dynamic Context nodes, one in ViewController and the other in Component Controller and finally create a context mapping between them?
Regards,
Johan Kriek.
Hi Johan,
use this to cretate context node dynamically where it is(view or component).
CL_WD_DYNAMIC_TOOL=>CREATE_NODEINFO_FROM_STRUCT
just pass structure name and root node info to this method.you will have context node with attributes.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Johan,
I found a method IF_WD_CONTEXT_NODE_INFO~ADD_NEW_MAPPED_CHILD_NODE that seems to be the one that I am looking for.
I do have same idea but i have been trying to give solution by using above method,unfortunately here my server is down.check the below code. i didnt check this code due to server down.
DATA: lo_nd_purchase_header TYPE REF TO if_wd_context_node,
lo_el_purchase_header TYPE REF TO if_wd_context_element,
ls_purchase_header TYPE wd_this->element_purchase_header,
lo_node_info type ref to if_wd_context_node_info,
lo_child_node_info type ref to if_wd_context_node_info,
MAPPING_INFO type WDR_CONTEXT_MAPPING_INFO.
* navigate from <CONTEXT> to <PURCHASE_HEADER> via lead selection
lo_nd_purchase_header = wd_context->get_child_node( name = wd_this->wdctx_purchase_header ).
CALL METHOD LO_ND_PURCHSE_HEADER->GET_NODE_INFO
RECEIVING
NODE_INFO = lo_node_info.
MAPPING_INFO-controller = 'ZWDC_ALV'. "conponent name
MAPPING_INFO-path = 'PURCHASE_HEADER'. "Controller context node name
CALL METHOD LO_NODE_INFO->ADD_NEW_MAPPED_CHILD_NODE
EXPORTING
CHILD_NAME = 'PURCHASE_HEADER'
MAPPING_INFO = MAPPING_INFO
* IS_STATIC = ABAP_TRUE
RECEIVING
CHILD_NODE_INFO = lo_child_node_info
.
User | Count |
---|---|
86 | |
10 | |
10 | |
9 | |
6 | |
6 | |
6 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.