on 05-26-2009 3:36 PM
Hello,
I'm using a Tree component in my mainview. When clicking on a node, I get to expand the tree.
Now, I'd like to be able to search a node. For example, when I search for a node "material", a popup appears with all the nodes matching "material". After validating my selection, the popup closes itself and returns to the mainview. At this moment, the tree has to be expanded at the selected node, as if I had clicked on it...
I hope I've been clear enough. If not, feel free to ask 😃
Thanks for any help you can provide.
C.
Hi,
1. Select the row or node under which you want to search the corresponding node. for ex: root node
2. Press the button to open the search popup.
3. enter the Search input and press search. for ex: "material*"
4. Now with the help of method "get_static_attributes_table" of interface if_wd_context_node get all the elements of context node.
5. Now, Loop through elements table and build table for all elements having value for attributes starting with material like material_pepsodent, material_nike, material_1 etc.
6. Bind this table to the result table. Also keep the element index in the result table.
7. Now depending upon the user selection from result table, select the corresponding element using sel_lead_selection ( index = <selected_element> )
8. Also, you have to saet the property "expanded" equal to true. for this element as well as their corresponding parent element.
Please note that in WebDynro ABAP there is no event like "OnKeyPress". So do not expect that as you press "mat" result will be filtered for "mat".
Thanks,
Rahul
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
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.