cancel
Showing results for 
Search instead for 
Did you mean: 

tree inside a POP-up

Former Member
0 Kudos

Hi Experts,

I would like to create a tree inside a POP-UP window.

Does anyone have any idea how can I do this?

Where should I define node for the tree?

Its very urgent.

Regards,

Vishal.

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

hi vishal.....

now create a view and have the tree and nodes in it. bind this to a window and call this as a window from the main view.

---regards,

alex b justin

Former Member
0 Kudos

Thnaks Alex for the quick reply.

You told "call this as a window from the main view".

Do you mean calling by firing plugs or using some method? I would have reterive some data from the tree back to the calling value also. plz tell me how would i pass this data back to calling window.

Do you have any sample code for the same?

Regards,

Vishal.

Edited by: VISHAL GUPTA on Apr 29, 2008 10:56 AM

Former Member
0 Kudos

hi vishal.......

use code wizard to call the window to which the tree view is bound. use component controller to pass values between views.

---regards,

alex b justin

former_member189058
Active Contributor
0 Kudos

Hi Vishal,

1. If you need to pass data between two views, you need to keep that in the component controller context and map that to the view context.

2. Create a Window, say WI_POPUP

3. Create a View, say VI_POPUP_TREE

Now in this view, create context mapped from component controller context and layout containing TREE UI element.

4. Embed VI_POPUP_TREE in WI_POPUP.

5. In ur main view, u must be having a button on click of which you will show the popup with tree. In the event handler of that button click action do this:


data: l_cmp_api type ref to if_wd_component,
l_window_manager type ref to if_wd_window_manager.
l_cmp_api = wd_comp_controller->wd_get_api( ).
l_window_manager = l_cmp_api->get_window_manager( ).
if wd_this->m_popup1_1 is initial.
wd_this->m_popup1_1 = l_window_manager->create_window(
window_name = 'WI_POPUP'
button_kind = if_wd_window=>co_buttons_yesnocancel
message_type = if_wd_window=>co_msg_type_question ).
endif.
wd_this->m_popup1_1->open( ).

Note that BUTTON_KIND and MESSAGE_TYPE can be changed, Have a look at the attributes of IF_WD_WINDOW interface.

Regards,

Reema.