on 03-31-2015 7:22 AM
Hi Team,
please suggest me how can i check how many no of child instance are created when single ton property is checked and unchecked?
in my view below is what i know about singleton property, if i am wrong correct me.
Say there are two ALV's on a View:
ALV1 ---> NODE_SO_HEADER----> Displays all the Sales Orders.
ALV2 ---> NODE_SO_ITEMS ------> Displays all the line items for the Sales Order selected in ALV1.
NODE_SO_ITEMS is the child node for NODE_SO_HEADER and is declared as Singleton node.
Since this node is declared as singleton, at runtime, it holds the line item data only for the Lead Selected Sales Order from NODE_SO_HEADER and not for all the Sales Orders from the parent node.
Whenever the lead selection changes for the parent node, line item data for that lead selected order is fetched from database and populated in the child node.
Thanks in advance.
Hi SivaRamaKrishna,
Since you are using Singleton property for the node, then probably you must be using SupplyFunction/OnleadSelect to bind the data, as the lead selection changes.If you need the number of elements/insatance in the line items node, please check with the following snippet, where you are written the logic to bind the child node with new elements,upon lead select.
DATA: lo_node TYPE REF TO if_wd_context_node,
lines_count TYPE i VALUE 0.
lo_node = wd_context->get_child_node( name = 'NODE_SO_ITEMS' ).
lo_node->get_element_count( RECEIVING count = lines_count ).
Regards,
Harsha
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
85 | |
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.